<!DOCTYPE html> <html lang="en-US"> <head> <title>reference of svg-as-border-image</title> <style> div.border { width: 40px; height: 40px; background-color: blue; background-repeat: no-repeat; background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40"><rect x="0" y="0" width="15" height="15" fill="pink"/><rect x="25" y="25" width="15" height="15" fill="green"/></svg>'); } </style> </head> <body> <div class="border"></div> </body> </html>