ESP32 + SIM800L; modem not starting when GPS breakout board is connected
When you turn off the transistor the GPS unit floats to +5V and applies 5V to the TX and RX lines.
As the LilyGO is a 3V3 device you are applying an 'illegal' voltage to it.
To avoid this consider using a &quot;high side&quot; PNP transistor in the 5V line, driven eg by Q1.
Then the GPS unit is at ground potential when off.
You may still have issues with the GPS 5V level TXD and RXD but that is an issue you are going to have to address regardless.  TX data into the LilyGO is easily reduced to 3V3 max with 2 resistors. LilyGO pin27 to GPS RX may or may not work depending on the GPS levels. You may need to use a voltage upshifter there.
A &quot;clever&quot; noninverting driver can be made with an NPN transistor with base to 3V3 via a resistor,  emitter driven by the LilyGO and collector with a pullup to 5V.



simulate this circuit &ndash; Schematic created using CircuitLab