The future is unclear for a heart device aimed at preventing strokes in people at high risk of them because of an irregular heartbeat.

Early results from a key study of the device, Boston Scientific’s Watchman, suggested it is safer than previous testing found, but may not be better than a drug that is used to prevent strokes, heart-related deaths and blood clots in people with atrial fibrillation in the long term.

Atrial fibrillation, a common heart arrhythmia that affects millions of Americans, causes blood to pool in a small pouch. Clots can form and travel to the brain, causing a stroke.

The usual treatment is blood thinners like warfarin, sold as Coumadin and other brands. But they have their own problems and some are very expensive. The Watchman is intended to be a permanent solution that would not require people to take medication for the rest of their lives. It is a tiny expandable umbrella that plugs the pouch of blood, and is inserted without surgery, via a tube pushed into a vein.

A study four years ago indicated the device was at least as good at preventing strokes as warfarin, but the procedure to implant it led to strokes in some patients. The Food and Drug Administration required another test of its safety and effectiveness.

The new study was led by Dr. David Holmes Jr. of the Mayo Clinic in Rochester, Minn. He and the clinic have a financial stake in the device.

The study involved 407 patients — 269 assigned to get the device and 138 to get warfarin. It had three main goals, and it clearly met the first on safety — strokes, heart-related deaths, blood clots and serious complications a week after implant or release from the hospital.

The other goals were assessed based on 88 patients who were tracked for 18 months after treatment. Strokes and blood clots occurred no more often with the device in the patients. However, the results suggested it would not prove better than warfarin at 18 months on a wider measure — a combination of strokes, heart-related deaths or clots.