<!DOCTYPE html>
<html>
<body>
<h2>SVG mask Element</h2>
<svg width="200" height="120" xmlns="http://www.w3.org/2000/svg">
<defs>
<linearGradient id="gradient1">
<stop offset="0%" stop-color="#ffffff" />
<stop offset="100%" stop-color="#000000" />
</linearGradient>
<mask id="mask1">
<rect x="0" y="0" width="100" height="100" fill="url(#gradient1)" />
</mask>
</defs>
<rect x="0" y="0" width="100" height="100" fill="red" mask=" url(#mask1)"/>
Sorry, your browser does not support inline SVG.
</svg>
</body>
</html>