Ocean salt primarily comes from rocks on land and openings in the seafloor.
Salt in the ocean comes from two sources: runoff from the land and openings in the seafloor.
Rocks on land are the major source of salts dissolved in seawater. Rainwater that falls on land is slightly acidic, so it erodes rocks. This releases ions that are carried away to streams and rivers that eventually feed into the ocean. Many of the dissolved ions are used by organisms in the ocean and are removed from the water. Others are not removed, so their concentrations increase over time.
Another source of salts in the ocean is hydrothermal fluids, which come from vents in the seafloor. Ocean water seeps into cracks in the seafloor and is heated by magma from the Earth’s core. The heat causes a series of chemical reactions. The water tends to lose oxygen, magnesium, and sulfates, and pick up metals such as iron, zinc, and copper from surrounding rocks. The heated water is released through vents in the seafloor, carrying the metals with it. Some ocean salts come from underwater volcanic eruptions, which directly release minerals into the ocean.
Salt domes also contribute to the ocean’s saltiness. These domes, vast deposits of salt that form over geological timescales, are found underground and undersea around the world. They are common across the continental shelf of the northwestern Gulf of Mexico.
Two of the most prevalent ions in seawater are chloride and sodium. Together, they make up around 85 percent of all dissolved ions in the ocean. Magnesium and sulfate make up another 10 percent of the total. Other ions are found in very small concentrations. The concentration of salt in seawater (salinity) varies with temperature, evaporation, and precipitation. Salinity is generally low at the equator and at the poles, and high at mid-latitudes. The average salinity is about 35 parts per thousand. Stated in another way, about 3.5 percent of the weight of seawater comes from the dissolved salts.
Read more at oceanservice.noaa.gov