I want to wire up a float switch to fill my top off container so I don't overfill as it will be remote. I plan to splice a float switch into an extension cord. Do I need a 12v dpdt relay or will it work without?
Yes you definately need a 12 volt power supply or transformer. Float switches are low voltage and you really don't want line voltage going into your top off container.
(electrician 40 years)
Float switches are low or high voltage (your choice) but for safety you should go with low voltage.
Don't buy a cheap ebay solenoid valve, I can recommend redhat company for heavy duty industrial solenoids that never fail for me or my customers.
It's $50 solenoid you can trust years.
I bought many cheap ones and some of them leak.
Only my 2 cents...