The source is at the outlet and a switch loop is added to a new switch. The single pole switch currently in the wall has the black wire from the load pig tailed and the red wire from the line goes to the other terminal on the single pole switch.

Simple Question Regarding Wall Switch Wiring Electrical
How to wire wall switch. I know the red wire goes to the indoor light fixture. This wiring diagram illustrates adding wiring for a light switch to control an existing wall outlet. Instead of running a separate pigtail from the hot wire to each switch just leave the hot wire extra long. Connect the last switch in the usual manner looping the wire around the screw in a clockwise direction. Turn off the electricity carefully. Confirm the electricity is off at the spot.
The other set of wires contains 1 red 1 white and 1 black wire i assume this is the line. Wrap the end of the one of the ground wires around the green ground. Common applications include ceiling or hallway light switches. Circuit electrical wiring enters the switch box the black wire power in source attaches to one of the switch screw terminals fixture wiring exits the switch box the black wire power out wiring attaches to the other switch screw terminal. Pick a single pole light switch for most applications. Crimp the bare ground wires together with a crimp connector.
The hot source wire is removed from the receptacle and spliced to the red wire running to the switch. Screw on a wire cap to hold them together and insulate the ends. Locate your circuit breaker box and the circuit breaker specific to the switch to. The black wire from the switch connects to the hot on the receptacle. To connect the switches simply score the wire with your wire stripper and push the insulation to expose about 34 in.