How to Connect a Solar Panel to a Battery: 5 Steps (w/ Videos)

These instructions will show you, with step-by-step videos, one of the foundational skills of building DIY solar power systems: how to connect a solar panel to a battery.

By the end, you’ll be charging your 12 volt battery — or higher — with free solar energy.

(If that doesn’t get your blood pumping…I don’t know what will.)

Alright. Let’s get to it!

Materials & Tools


Note: I’ve listed the sizes I used and linked to either the exact materials I bought for my setup or materials that are compatible with it. Feel free to copy my setup. Otherwise, adjust the sizes of your components for the amount of current that’ll be flowing through your system.


Step 1: Understand the Wiring Diagram

Here’s the wiring diagram showing how to connect a solar panel to a battery:

It’s important to understand the following:

  • Don’t connect a solar panel directly to a battery. Doing so can damage the battery. Instead, connect both battery and solar panel to a solar charge controller.
  • It’s recommended you fuse your system. Safety best practices, y’all! Place one fuse between the positive battery terminal and the charge controller. Place another between the positive solar panel wire and the charge controller.

Step 2: Make the Battery Cables

I didn’t have pre-made battery cables lying around. So I decided to save some money and make my own.

Turns out it’s pretty easy. Here’s how I did it:

Cut two pieces of wire to the length you want and strip both ends. (I made one a little shorter to account for the fuse I’m going to attach to it.)

Put the fuse in the fuse holder. Use our fuse size calculator to find the right fuse size.

Connect one of the fuse holder’s wire leads to your shorter battery cable with your wire connector of choice. (I used a 12-10 gauge butt splice connector.)

Shrink wrap the connector with heat shrink tubing and a heat gun.

Slide a piece of heat shrink tubing onto each battery cable (before crimping the terminal connectors…don’t forget until after like I did 😅).

Then crimp the battery terminal connectors onto the battery cables and shrink wrap the connections. Look at your battery terminals to know which size connectors to use. Mine uses 1/4″ ring terminals.

Battery cables complete!

Now they’re ready to be connected. ⚡

Step 3: Connect the Battery to the Charge Controller

Note: At this point I put on my gloves and safety glasses because places like Advanced Auto Parts recommend wearing them when working with batteries.

Follow the instructions in your charge controller’s manual for connecting it to the battery. I’ll show you how to connect the charge controller I used, the Renogy Wanderer:

Connect the negative battery cable, the one without the fuse, to the “-” battery terminal on the charge controller.

Connect the positive battery cable, the one with the fuse, to the “+” battery terminal. (Renogy recommends connecting the battery cables to the charge controller before connecting them to the battery.)

Connect the battery cables to the battery terminals — negative first, then positive. Before connecting the positive cable, I like to touch it to the positive battery terminal because sometimes there will be a little spark.

Your charge controller should turn on or light up to indicate the battery is properly connected. For instance, mine has a light that turns on.

The battery is now connected!

At this point, your manual may tell you how to program the charge controller for your battery type, voltage, etc.

Mine has a button which I can press to indicate battery type. It defaults to sealed lead acid, which happens to be the type I’m using. So I just kept it at the setting it was on.

Step 4: Connect the Solar Panel to the Charge Controller

Next up — connecting the solar panel!

Most solar panel cables come with pre-attached MC4 connectors. To connect a solar panel to a charge controller, you need MC4 solar adapter cables.

MC4 solar adapter cables are needed to connect a solar panel to a charge controller

(These are basically a length of solar PV wire that has an MC4 connector at one end and is stripped at the other. For my setup, I made my own by assembling a male and female MC4 connector. I also bought MC4 solar extension cables. The extension cables are optional based on how far apart your solar panel and charge controller are.)

For the panel’s positive cable, connect the MC4 inline fuse, positive extension cable (if using), and then the MC4 adapter cable.

For the panel’s negative cable, connect the negative extension cable (if using) and then the MC4 adapter cable. Don’t let the exposed wires touch!

Follow the instructions in your charge controller’s manual for connecting it to the solar panel. I’ll show you how I connected mine:

First connect the negative solar cable to the charge controller, then connect the positive. Your charge controller should turn on or light up to indicate that the panel is properly connected.

Everything is now wired together!

Just one more step…

Step 5: Put the Solar Panel in the Sun

Put your solar panel in direct sunlight at the best tilt angle for your location (this is easy to do with my $11 DIY solar panel mount).

Once you do, your charge controller should indicate that the battery is charging. Mine has a light that flashes when the battery is charging normally.

Just like that, you’re DONE. 🥳

Now you know how to charge a battery with a solar panel!

Sit back and let the panel collect all that free solar energy. The charge controller will stop charging the battery once it’s full.

How Long Does It Take to Charge a Battery with a Solar Panel?

Use our solar battery charge time calculator to find out. The answer depends on a lot of factors.

As an example, here are the specs for the setup I used:

According to our calculator, with this setup it’ll take about 7 hours of direct sunlight to charge the battery from 50% (the recommended depth of discharge for lead acid batteries) to fully charged.

But change any part of the setup — e.g. swap in a 50 watt solar panel, a lithium battery, or an MPPT charge controller — and the charge time will be different.

So yeah, definitely recommend the calculator for that question.

Give it a go:

3 DIY Solar Power Projects You Can Build Now

What you effectively just built was your first solar panel setup. That’s a big deal!

Now that you’ve passed that milestone, here are some more projects I think you’d be interested in building:

1. Solar Car Battery Charger

By connecting a solar panel to a 12V battery, you’ve actually made a solar 12V battery charger. Car batteries are 12V batteries, so you could just as easily use the system you just made — or the near-identical one described in this tutorial — to solar charge your car battery.

2. DIY Solar-Powered 12 Volt LED Lights

These solar-powered LED lights use essentially the same system you just built. All you need to do now is connect some LED strip lights to your battery, and you’re good to go.

3. Solar Charger for an Electric Bike

You can build a modified version of the solar charging system you just made to solar charge an electric bike. Or, just connect an inverter to your 12 volt battery and plug the ebike charger in like normal.

Share This Article
Alex Beale
Alex Beale
Hi, I'm Alex. I started Footprint Hero to help people reduce their environmental impact. My current obsession is DIY solar power projects, which I've been building since 2020.

16 thoughts on “How to Connect a Solar Panel to a Battery: 5 Steps (w/ Videos)”

    1. Thank you Cary! For 2 panels, you’d need to connect them in series or parallel, then connect everything the same way. If you connect them in parallel, you want to make sure your system components (e.g. charge controller, battery, and wiring) can handle the new max current. If you connect them in series, you want to make sure your components are compatible with the new voltage.

  1. Good info Alex! I have a project I am struggling with. It is a small tool that I run on 8 D cell batteries and it will last about 2 months running 24/7. I would like to change to a solar, rechargable lithium battery set up so I don’t have to change batteries out and it could run all year? Any suggestions?

    1. Hmm so do you put the D batteries in a battery compartment in the tool? Because then you’d need some D-cell shaped lithium batteries. Never used those but just did a quick google search and there are some out there (these are what came up: … they’re not cheap though!). If you got those it’d be easier to just charge them from an outlet rather than solar.

      Or do you connect the D batteries in series to create a 12 volt battery bank that you then use to power the tool? In that case you could use the setup described above but get a 12v lithium battery and a charge controller that is compatible with 12v lithium batteries.

  2. Hi jeff . I’m James Loew from Youngstown Ohio. I only have a 7 watt panel and a 12 volt rechargeable solar battery and , I have a solar controller , all from harbor freight . Going to try recharge battery only reading 7.2 volts . Will let you know how it goes. Just my battery is okay. Was not sure how to do it? The hook up of wires.ty

  3. Your tutorial is very useful. It will really assist me in building alternate power supply here.

    I want to build a solar power system that can power a LCD television, some LEDs bulbs for some rooms, radio and fan.

    I want to use 24V lithium battery, pls suggest the capacities of the solar panels, solar charge controller, inverter and other accessories that I can used to power the items about. Pls include the links to purchase them online.

    Waiting for your response

    1. Thanks for your question, John. Unfortunately — and despite the fact that I love discussing anything and everything solar! — because I’m so busy at the moment, I’m currently not doing any consulting or one-on-one advising.

      Doing so would take away from the time I have to test equipment, do solar builds, and put together tutorials like this one.

      Thanks again and good luck with your solar power system!

Leave a Comment

Your email address will not be published.