The state shut down shellfish harvesting from Gloucester to Salisbury recently after potentially lethal red tide was found, and state and local officials say the ban could last three weeks or longer.

“Don’t touch any clams or mussels or harvest any shellfish unless you want to die,” Salisbury harbormaster Ray Pike said Monday. “That’s been the case for over a month in New Hampshire and it came into Salisbury and (the Merrimack River) about two, three weeks ago.”

Pike said only commercial digging is usually allowed in the Merrimack and that has been prohibited since mid-June when red tide was discovered.

Waters, tributaries and tidal flats off Essex, Ipswich, Rowley, Newbury, Newburyport and Salisbury have been affected by red tide, the common name for an algae bloom that chokes out oxygen in the water. The red tide contains paralytic shellfish poison, which can cause diarrhea, paralysis or death.

State fisheries officials said it will be at least three weeks until tests determine whether the flats can reopen.

Like Pike, Gloucester Shellfish Warden Peter Seminara is urging the public to refrain from all shellfish harvesting at city beaches and flats during the red tide closure to guard the health of the public and Gloucester’s commercial shellfish industry.

Seminara said his staff documented 16 violations in the past week — including one Thursday that involved 70 pounds of illegally harvested surf clams and another on the Fourth of July involving 40 pounds of surf clams. Both incidents occurred at Wingaersheek Beach.

“We’re really trying to alert all beachgoers to the health dangers of taking shellfish during the closure,” Seminara said Friday. “It presents a danger to the public’s health and it does have an economic impact on our commercial clamming industry if people start getting sick from shellfish harvested in Gloucester.”

Pike said the Merrimack River will “remain closed to digging until someone tests it clean. They want to get it open but it is a hard thing to rush because it takes resources. There’s also no recreational digging anywhere on the Merrimack because it has been classified as moderately contaminated. So, you can’t dig unless you are in business.”

Seminara said the state Division of Marine Fisheries and his own staff continue to test harvesting areas on a weekly basis. Because of testing protocols, he said it will be at least three more weeks before the ban is lifted along the North Shore.

“We need three consecutive tests with descending counts to open the areas,” he said. “So, that’s at least three more weeks. But we’re still patrolling daily.”

Seminara said people — particularly visitors from out of town — should refresh their understanding of the permitting rules for shellfish harvesting.

“First of all, they need a permit and they need to be a Massachusetts resident to harvest shellfish from Massachusetts shellfish beds,” Seminara said. “Most importantly right now, they absolutely cannot take any shellfish from anywhere in Gloucester until further notice.”

Pike also said he doesn’t expect the clamming ban to be lifted any time soon.

“The diggers will be back once the warning is lifted,” he said. “We’ve already had many closures due to rainfall this summer and we have also had (combined sewage overflows) when it rains, which require a three- to five-day closure.”

If cited criminally, illegal harvesters could face a minimum fine of $500 for harvesting during a red tide closure and other potential fines up to $2,000 and two years in jail if convicted.

Pike hasn’t caught any red tide violators in Salisbury.