I am building a project that has to do with underwater and I am having trouble waterproofing the electronic and the depth is about 15-20 feet. How will I assure that the electronic will be waterproof at that depth. Thank you
15-20 ft underwater is a about 7 - 10 psi (0.5 - 0.7 atm). A sealed polycarbonate box thick enough to withstand that pressure should do the trick. If you need cables to/from the electronics that’s a bit more work.
You can also consider filling the enclosure with a nonconducting, incompressible fluid such as oil. That’s what they do with stuff that has to go really deep (think ROVs like they use on oil rigs.) Of course your components cannot have any air voids, and they have to be compatible with the fluid.