FIRST, THE GOOD news: In its annual survey of water quality at the nation's beaches, the Natural Resources Defense Council (NRDC) selected Ocean City this year as one of its four "Beach Buddies" -- beach towns that have made the most progress. Ocean City's programs include weekly water quality monitoring, careful controls over the flow of storm water, and the use of shrubs and other natural "buffers" to prevent erosion and the contamination of ocean water. Ocean City also now takes part in the Maryland Coastal Bays program, an Environmental Protection Agency project that joins the city, the state and Worcester County to promote farming and development projects that won't contaminate the water. Local officials should be particularly proud of themselves, considering that the NRDC gave a "Beach Bum" award for poor water quality monitoring to quaint Bar Harbor, Maine, which has been regarded as boardwalk-bound Ocean City's aesthetic superior -- but no more.

Now, the bad news: Ocean City is an exception. According to the NRDC survey, the nation's beaches had more than 18,000 days of closings and water quality advisories last year, up 51 percent from the previous year. (Maryland beaches suffered a cumulative 99 days of closings in 2003; Delaware had 60). Although some of the increase in advisories can be attributed to better water-quality monitoring, the rise also reflects a widespread failure to control water pollution. As the Washington region well knows -- considering the difficulty that local governments have had in tackling the pollution problems of the Chesapeake Bay -- coastal water problems can be frustratingly complex to remedy, because beach water pollution comes not only from easily identifiable sources, such as faulty sewage pipes, but from agricultural runoff, lawn fertilizers, individual septic tanks and erosion as well. By definition, keeping beach waters clean enough for swimming requires the cooperation of a region's farmers, developers, manufacturers and city dwellers, as well as residents of the beach community.

For that reason, preserving clean coastal waters almost always requires state-level, and sometimes federal-level, cooperation, both of which are moving forward at a glacial pace. In its first days in office, the Bush administration shelved regulations that would have required sewer operators to notify the public of overflow -- a major source of beach pollution -- and never managed to resurrect them. The EPA has been debating rules that would ease sewage treatment standards too, in the case of heavy rains: That too could have consequences for the local beach. The president's proposed 2005 budget contains substantial cuts in at least one program that funds state efforts to upgrade sewage treatment, although EPA officials say they expect the cuts to be balanced by other programs.

But it is also true that about 20 states have yet to adopt the EPA's standards for water quality and that nationally, monitoring programs remain uneven. Technology is bringing ever more rapid systems of detecting dangerous levels of bacteria, but unless systems are in place to use them, they'll have no impact. State and local economies benefit enormously from beach tourism, as Ocean City has realized. It's not just the swimmers, in the end, who benefit from better coordination and policies.