In the earliest days of home audio, speakers were often connected with simple electrical wires, or "lamp cord." This substitution works in the opposite direction as well, and you can use speaker wire as electrical wire in many cases. It's best to restrict its use to low-power or low-amperage scenarios, and there are some important limitations you'll need to know before you start.
Speaker Wire vs. Electrical Wire
If you go to your nearest hardware store and look at the electrical wire that's sold for making DIY lamps and power cords, you'll see that it's made up of two insulated wires joined together side by side in a sort of flat figure-eight shape. One side is typically marked either with ridges or printing so you know which is which.
If you go to the speaker-wire section of a hardware or department store and look at speaker wires, you'll see that they are very similar indeed. The only difference is that speaker wire typically has clear outer insulation, while electrical wire might be black, brown, white or some other color. That similarity isn't an illusion; the wires are very much alike and can be used interchangeably in many circumstances.
Speaker Wire for Power Cable
A common use, for example, might be to use speaker wire as the power cable for a lamp or other low-power electrical device. Typically, you'll need to disassemble the device at least partially to remove the old cord. Inside, the power cord usually attaches through some kind of screws or terminals. Before you remove the old one, make a careful note of which screw or terminal is connected to the unmarked, or hot, side of the wire. Attach the new wire accordingly.
At the wall end of the cord, you'll need to attach a plug. These come in solder-on and solderless screw-on versions, but the simplest just snap on over the end of the wire and pierce the insulation to make an electrical connection. One terminal of the connector will be labeled for the hot wire and the other for the neutral. Position them accordingly, snap the connector closed and you're done.
A Few Limitations
Speaker wire comes in many different gauges, each with a number. The smaller the number, the bigger the wire and the more power it can handle. A lamp draws very little current, especially with modern LED bulbs, so ordinary speaker wire of even 18 or 20 gauge is fine. For higher-drawing devices, like a kitchen appliance, you'd be better off using heavier 16-, 14- or 12-gauge wire. Heavier wire has less resistance, so it's less likely to overheat in daily use.
Ideally, the speaker wire you use should be the pure copper variety. Lower-cost speaker wire is made of copper-covered aluminum, which also conducts electricity well, but aluminum is more prone to heat-related problems.
Wiring in the Wall
Aside from use as a power cord, you might consider running speaker wire through your walls in low-voltage applications, such as thermostats, sensors and hard-wired smart-home devices. In these cases, you won't have to worry about excess amperage making the wire heat up, but you will need to buy the right kind of speaker wire.
In most jurisdictions, in-wall wiring must be burn-resistant in order to meet building codes; otherwise, fire could travel along the insulation and burn down your house. Code-compliant speaker wire carries the CL2 or CL3 rating, which should be printed along the side. If you want to run the wire through a heat duct, you'll need wire with the CL2P or CL3P rating.