Two possibilities depending on new or existing outlet, and other factors and preferences.
The most common method is to just switch the top half of the outlet so a lamp can be plugged in and operated by the switch, and a fully operational outlet is available from the bottom half of the outlet. To do this you run a wire of the correct size (2 conductors with ground) from the switch to the outlet. You hook one of the switch wires to the top half brass screw and one to the hot wire on the outlet (from panel, not switched). Then break out the small connector between the brass screws on the outlet. The top and bottom halves of the outlet will work independently.
Another way is to just run the circuit from the feed thru the switch, and just switch the hot (black) and run the switched hot and neutral and ground to the outlet and the outlet is powered just as if it were a light. The entire outlet is powered by the switch. TURN OFF POWER BEFORE DOING WIRING.
The most common method is to just switch the top half of the outlet so a lamp can be plugged in and operated by the switch, and a fully operational outlet is available from the bottom half of the outlet. To do this you run a wire of the correct size (2 conductors with ground) from the switch to the outlet. You hook one of the switch wires to the top half brass screw and one to the hot wire on the outlet (from panel, not switched). Then break out the small connector between the brass screws on the outlet. The top and bottom halves of the outlet will work independently.
Another way is to just run the circuit from the feed thru the switch, and just switch the hot (black) and run the switched hot and neutral and ground to the outlet and the outlet is powered just as if it were a light. The entire outlet is powered by the switch. TURN OFF POWER BEFORE DOING WIRING.