Source code
Revision control
Copy as Markdown
Other Tools
<!DOCTYPE html>
<meta charset=utf-8>
<title>valid src</title>
<img src="a:foo.com" alt><!-- scheme-private -->
<img src="foo:/" alt><!-- scheme-private-slash -->
<img src="foo://" alt><!-- scheme-private-slash-slash -->
<img src="foo:/bar.com/" alt><!-- scheme-private-path -->
<img src="c:/foo" alt><!-- scheme-private-single-letter -->
<img src="madeupscheme:/example.com/" alt><!-- scheme-private-single-slash -->
<img src="file:/example.com/" alt><!-- scheme-file-single-slash -->
<img src="ftps:/example.com/" alt><!-- scheme-ftps-single-slash -->
<img src="gopher:/example.com/" alt><!-- scheme-gopher-single-slash -->
<img src="ws:/example.com/" alt><!-- scheme-ws-single-slash -->
<img src="wss:/example.com/" alt><!-- scheme-wss-single-slash -->
<img src="javascript:/example.com/" alt><!-- scheme-javascript-single-slash -->
<img src="mailto:/example.com/" alt><!-- scheme-mailto-single-slash -->
<img src="madeupscheme:example.com/" alt><!-- scheme-private-no-slash -->
<img src="ftps:example.com/" alt><!-- scheme-ftps-no-slash -->
<img src="gopher:example.com/" alt><!-- scheme-gopher-no-slash -->
<img src="wss:example.com/" alt><!-- scheme-wss-no-slash -->
<img src="mailto:example.com/" alt><!-- scheme-mailto-no-slash -->
<img src="data:text/plain,foo" alt><!-- scheme-data-no-slash -->
<img src="http💩//:foo" alt><!-- path-contains-pile-of-poo -->
<img src="http://%25DOMAIN:foobar@foodomain.com" alt><!-- userinfo-username-contains-percent-encoded -->
<img src="//foo/bar" alt><!-- scheme-schemeless-relative -->
<img src="/" alt><!-- path-slash-only-relative -->
<img src="/a/b/c" alt><!-- path-simple-relative -->
<img src="/a%2fc" alt><!-- path-percent-encoded-slash-relative -->
<img src="/a/%2f/c" alt><!-- path-percent-encoded-slash-plus-slashes-relative -->
<img src="?" alt><!-- query-empty-no-path-relative -->
<img src="#" alt><!-- fragment-empty-hash-only-no-path-relative -->
<img src="#/" alt><!-- fragment-slash-relative -->
<img src="#;?" alt><!-- fragment-semicolon-question-mark-relative -->
<img src="#β" alt><!-- fragment-non-ascii-relative -->
<img src="foo.com" alt><!-- scheme-none-relative -->
<img src=":" alt><!-- path-colon-relative -->
<img src=":a" alt><!-- path-leading-colon-letter-relative -->
<img src=":foo.com" alt><!-- path-leading-colon-chars-relative -->
<img src=":/" alt><!-- path-leading-colon-slash-relative -->
<img src=":#" alt><!-- path-leading-colon-hash-relative -->
<img src=":23" alt><!-- path-leading-colon-number-relative -->
<img src="/:23" alt><!-- path-slash-colon-number-relative -->
<img src="::" alt><!-- path-leading-colon-colon-relative -->
<img src="::23" alt><!-- path-colon-colon-number-relative -->
<img src="/💩" alt><!-- path-slash-pile-of-poo -->
<img src="file:" alt><!-- scheme-file-scheme-only -->
<img src="file:/" alt><!-- scheme-file-slash-only -->
<img src="file://" alt><!-- scheme-file-slash-slash-only -->
<img src="file:test" alt><!-- scheme-file-no-slash -->