You shouldn't hook a solar panel directly to a battery. You'll want to get a solar charge controller (SCC). You need to look for the input voltage of the SCC and the output voltage of it. If the input voltage of the SCC is bigger than the VOC of your solar panel, it will work well with the panel. If the output voltage of the SCC matches the nominal voltage of your battery, it should work well with each other.
What is the VOC of your solar panel?
What is the type of battery you're using (SLA, LifePO4, etc)?
What is the nominal voltage of the battery (12v, 24v, etc.)?
What is the capacity of your battery (50Ah, 100Ah, etc)?