I would like to build a free open-source copylefted personal website under the Creative Commons Attribution-ShareAlike license (or a similar such license).

However, I would like to still be able to include some proprietary content, such as a Google Analytics tracking code or a Twitter widget, on the website.

What would be the best way to license my original content (and redistributed copylefted content such as from Wikimedia Commons) as CC BY-SA, but still respect the licenses of proprietary third-party content, such as a Google Analytics tracking code, social-media widgets, an embedded Google Maps iframe, or an embedded YouTube video?

For items like Twitter, Google Maps, or YouTube, I could just post hyperlinks to the content instead of embedding it if I really needed to, but I cannot do that for the Google Analytics tracking code (it needs to be on the website to work). Or can open-source websites only use open-source software (e.g. Matomo or Open Web Analytics)? I am not sure if I can claim using Google Analytics code is fair use, since free open-source alternatives to Google Analytics already exist.

  • 1
    There are different parts of a website that could be licensed. Do you talk about licensing the primary content of a page (i.e., the blog post in a blog)? Or the HTML/CSS/JavaScript?
    – unor
    Mar 26, 2018 at 3:09
  • I did think about that. If I understand the legalese correctly, Creative Commons licenses are not intended to be used for source code (i.e. the HTML, CSS, JavaScript, etc. used to build the site). So if the license only applies to final content and not the source, then I suppose I have less to worry about. Could I embed a Google Maps iframe in a CC-BY-SA website though, if an open-source alternative to Google Maps exists (e.g. OpenStreetMap)? What about a Twitter widget and other proprietary social-media widgets (e.g. AddThis)? Mar 26, 2018 at 13:15
  • Would an easier solution be to simply state that "all content is licensed as CC BY-SA unless otherwise indicated?" Then perhaps put a link to a new page listing any proprietary content used on the website that the CC BY-SA license does not apply to. Am I allowed to do that? Or is that too complicated or unneccessary? Mar 26, 2018 at 13:28
  • Hm. Okay. Google Maps Terms of Use says that you can always embed Google Maps as fair use without permission. Though the Terms of Use for Google Analytics say the opposite (thus my original question). But if the CC license does not apply to JavaScript, then that is moot. So the only thing that seems questionable for inclusion then might be social-media widgets. Mar 26, 2018 at 13:37

1 Answer 1


The license you apply only covers the content you created. If you incorporate someone else’s content, you should make clear that it’s not your content. Without making it clear, your readers might wrongly assume that the permissions you give for your content also apply to the third-party content.

Relevant Creative Commons’ FAQ:
May I apply a CC license to my work if it incorporates material used under fair use or another exception or limitation to copyright?

Be specific in your license notice

A website consists of many different parts that could be licensed, so you should ideally be specific for which part the license is intended.

And you should note that not (necessarily) all content on the page falls under this license.

Your license notice could start with something like

Except where otherwise noted, […]

and include which parts are licensed, e.g.

content on this site is licensed under […]

this blog post is licensed under […]

images on this site are licensed under […]

In addition, you could also mark up in a machine-readable way (e.g., with RDFa) which content falls under CC BY-SA.

Mark third-party content

Ideally, your readers can identify the content that isn’t subject to the CC BY-SA license, and possibly also learn what they are(n’t) allowed to do with it.

To identify the third-party content, you could, for example, provide notices next to that content, or you could reference that content in the footer (e.g., next to your license notice).

Depending on the nature of the third-party content, you might of course have to meet some requirements:

  • If the third-party content is licensed under a compatible license, you’ll typically have to provide an attribution.

  • If the third-party content isn’t licensed under a compatible license, but its use is allowed by law (fair use, public domain, quoting etc.), follow that law’s requirements (if any).

  • If the third-party content isn’t licensed under a compatible license, and its use isn’t allowed by law, but you have got that party’s permission, follow their rules (if any).

For some best practices, see Marking third party content in Creative Commons' wiki.

Embedding third-party content

Depending on the parts your license notice refers to, you might not need to mark items as third-party content at all.

For example, if your license doesn’t apply to the HTML/JavaScript, a tracking script like Google Analytics isn’t affected; if your license only applies to blog posts, a social media widget in the site footer isn’t affected; if your license only applies to text, a video isn’t affected.

Note that the existence of a free/libre alternative is irrelevant for deciding if fair use applies.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.