Outlets above baseboard heater ends (not above element)

I’ve got a baseboard heater that’s 9 ft long and electrical receptacles directly above each end of the heater. It appears safe since they’re above the end caps of the heater (where thermostats would usually mount) and away from the element by about 6’’. Would this result in code violation, or should I cap one of the boxes and move the heater a few inches?

Thank you.

You did not mention if it was baseboard electric or hydronic.

Yes it makes a difference.

Electric ones I have had installed did not allow per manufacturer instructions.

Exactly!

As other have stated the NEC doesn’t directly prohibit the receptacles above electric baseboard heat but references the manufacturers listing of the heating product.

Sometimes you may create a violation in trying to fix another.

From here: http://ecmweb.com/content/stumped-code-0

Q. What are the rules on spacing receptacles in a dwelling unit?
A. A receptacle outlet must be installed in every kitchen, family room, dining room, living room, sunroom, parlor, library, den, bedroom, recreation room, and similar room or area so that no point along the wall space is more than 6 feet, measured horizontally along the floor line, from a receptacle outlet [210.52(A)] (Figure).