This question about splitting a (passive) guitar signal come up regularly and so here is a bit of a ramble on the various ways, their advantages and disadvantages...
Boggo simplo...One plug to two plugs guitar cable.
Cheap as, no extra boxes to buy, no extra cables to find.
Downside. The impedance the guitar 'sees' is now the resultant of two inputs in parallel. If they are, as is usual, One meg Ohm then 500k Ohms will barely make a difference in most cases but there will be some loss of signal and possibly HF tone loss. You are also adding extra cable capacitance but that should not matter unless they are very long. i.e. over 3mtrs.
Using a DI box with a 'slave' output is no better in the vast majority of cases since the two jacks are invariably just in parallel*. A passive DI box will also have an input impedance likely no higher than 220k and possibly half that. Again, might not matter, depends on the guitar. An 'active' DI box will be better from the loading point of view but of course more expensive and needs phantom power or a battery.
Both the above situations can be fixed by introducing a 'buffer' into which the guitar is plugged. Note, this can be any pedal which is NOT of the daft "true bypass" variety. All Boss pedals are I think buffered? Now you can split the output with impunity. The pedal can be any effect, does not need to be 'on' just powered. You can of course buy dedicated buffer boxes but they always seem pricey to me for what they are and you might as well get an EQ say for a bit more dosh?
Last but not least is the bogey of a 'ground', aka hum aka earth loop. Whenever you connect two different devices together you run the risk of creating a ground loop and thus hum and sometimes other noises. The situation needs specific remedies so we will have to hope it does not occur but tackle it if it does.
*Orchid Electronics make an active DI box with an active split. Very good quality and not too expensive.
https://www.showbitz.co.uk/product/orchid-electronics-classic-di-box/ (I have no connection to the company in any way)
Dave.