Rather than create my own software, can I just take existing GPL software and provide a cloud service around it? Will that be legal?

  • 8
    What makes you think you might not be able to do so? Please edit to explain. Commented Mar 26, 2021 at 10:58
  • 10
    My explanation...... me=noob => Commented Mar 26, 2021 at 14:55
  • 3
    Maybe, he asked because he is scared of breaching copyright? Better ask first before having a problem later.
    – Kai Petzke
    Commented Mar 27, 2021 at 12:12
  • 2
    A lot of companies would go out of business if you couldn't. Commented Mar 28, 2021 at 15:12
  • 1
    There's a reason the LAMP stack took off. Commented Mar 29, 2021 at 3:20

4 Answers 4


You can indeed. GPLv2 and GPLv3 only require that you distribute the source code when you're distributing the binaries. In the case of software-as-a-service you're not distributing binaries and, as such, you're under no obligation to distribute your source code either. This is sometimes referred to as the SaaS loophole

  • 12
    @user1034912 - I mean, I always do MIT license myself lol. Whereas GPL is (mostly) share and share alike MIT is not. But, speaking for myself, I'd rather people use my library and bolster my download count then open source any code that's using my library. To each their own!
    – neubert
    Commented Mar 26, 2021 at 2:26
  • 10
    @user1034912 because GPL was created before cloud was a thing. There is also AGPL Commented Mar 26, 2021 at 11:09
  • 7
    @user1034912: The "swoop it away" is kind of the point of the GPL and other open sources licenses. The author put the software under the GPL specifically to allow other people to use and modify it. All of my personal projects are GPL.
    – JRE
    Commented Mar 26, 2021 at 11:37
  • 6
    @user1034912 I prefer MIT/BSD alikes either. What is the point of creating software for everyone and then release it under GPL license? You just seriosly limit your audience; most commercial (closed source) companies skip your code entirely due to the GPL. (License is first thing to look at while searching for reusable components - if it is GPL, then we just won't use it.) Development should be joy :)
    – Arvo
    Commented Mar 26, 2021 at 12:03
  • 6
    @user1034912, why would it be bad for the developer? They write the software to be used. If someone adds a value by providing all the computing resources to run it on, they can get paid for that and that's OK. I'd even say calling it a loophole is wrong, because it wasn't intended to be prohibited.
    – Jan Hudec
    Commented Mar 26, 2021 at 13:42

Yes, the GPL is a free software licence, and one of the properties of free (as in freedom) software is that you can use it for anything, including providing commercial online services.

This is not only legal; it is common. Ángel’s answer provided some good examples. A comment on the question mentioned the LAMP stack (half of which – Linux and MySQL – is GPL v2). Other examples are KVM, which is licenced under GPL v2, and OpenVZ (which is apparently GPL v2 as well, but it is split over many repositories so I have not verified this), both of which are used to provide VPS services.

There is one thing you should watch out for: the Free Software Foundation also released a licence called AGPL (Affero General Public Licence), which is similar to the GPL. It adds a requirement to distribute (on request) source code to users who interact with the software over a network, even if those users never receive a copy of the object code. The AGPL addresses the concern you raised in your comment on the other answer, about people locking up GPL’d software.

  • Personally, I think responses to comments should (mostly) be in the comments. If the OP edits their question only then should the answer be updated imho. I mean, comments can and often are deleted or moved to chat or whatever. If they are then half your answer ceases to have any context. It's just gratuitous information that's not related to the question at hand. And in any event, people shouldn't have to wade through a whole mess of comments to determine why a part of an answer is relevant. I mean, people are free to upvote what they will but I will not be copying your strategy!
    – neubert
    Commented Mar 30, 2021 at 12:34
  • @neubert (1/2) “Personally, I think responses to comments should (mostly) be in the comments.” This is not a “ response[] to comments”: the one time the answer mentions a comment, it does so merely to attribute an example that fits naturally into the answer. It would still make just as much sense if the comment was unavailable. “If the OP edits their question only then should the answer be updated imho.” What is so bad about editing answers? Commented Mar 30, 2021 at 12:59
  • @neubert (2/2) “It's just gratuitous information that's not related to the question at hand.” It is just as relevant as [Ángel’s answer] (which I upvoted, by the way), which has literally just three words that address the actual question. That answer has no comments and a positive score. Commented Mar 30, 2021 at 12:59

There are three general flavours of the GPL around:

  • The AGPL forces you to hand out source code to any user of your software upon request. For the AGPL, it doesn't matter, if the users downloaded the software as a binary to their machine or if they use it over a network on your server.

  • The GPL requires you to hand out source code only, if you provided a binary. For software running on a server, you don't need to provide source code.

  • The LGPL is the least restrictive: If you use LGPL code in a project, and distribute binaries, you only need to provide the source code of the LGPL parts, and the ability for the user to run the binary even after updating / upgrading the LGPL parts. This requirement is usually fulfilled by dynamically linking against LGPL libraries.

So, in your case, where you want to run a proprietary cloud service based on free software: Yes, you can do that with GPL software, but not with AGPL software.

Please keep in mind, that GPL and AGPL are infectious: If you have 500,000 lines of your own code and 5,000 lines of GPL code in a project, the whole joint work is still GPL. And if there are 1,000 more lines of AGPL in that project, it will even be AGPL.

LGPL on the contrary does not take over your code: You may link against LGPL libraries, most notable Linux/GNU libc, and don't loose any rights to your proprietary code.

  • -1 I upvoted this answer, but then realised that it does not actually answer the question. Commented Mar 27, 2021 at 13:07
  • 2
    regarding "infectious" licenses: GPL and AGPL are no different from any other software licenses: If you're given a possibility to use some code with a certain set of terms, then you must abide by any restrictions there are. Or not use the code at all. You can't expect to somehow get away by diluting the code into your own. After all, you wouldn't expect to be able to do that if you bought a commercial license for some (non-open) source code either?
    – ilkkachu
    Commented Mar 27, 2021 at 20:48
  • Thanks for pointing out AGPL. Though as I read about this, it doesn't give the ultimate protection from SaaS-ing up a GPL. It just forces the SaaS-er to share his code (such as user/server management side of the code). Commented Mar 28, 2021 at 1:08
  • 3
    @ilkkachu Clearly, when the author said “infectious”, they meant “copyleft”. Their explanation was not the best, but that does not change the fact that GPL and AGPL are different from other licences. Commented Mar 28, 2021 at 3:19
  • 1
    More often, though, you will have 5,000 lines of your own and 500,000 provided by someone else.
    – Ángel
    Commented Mar 28, 2021 at 23:01

Yes, you can. You can for instance provide a machine running a Linux kernel (GPLv2), with a web server using GnuTLS (LGPLv2.1+) and a web site built on Wordpress (GPLv2+).

From a business point of view, you should however take into account whether that is accessory or the main value of your service and which additional value you are providing.

For example, it would seem unlikely that a custom OS you coded from scratch performed better than using Linux (or other existing OS), and the actual OS is unlikely to matter for the service you will be providing.

On the other hand, if everything you provide is available by existing software (which is perfectly fine), you should mind which value you are providing versus your competition. Do you offer local support? Is it part of other services? Do you have a better expertise than other companies? (e.g. Automattic employing the main Wordpress developers) Are you much cheaper? Your business may flourish without any of them, but you may then rely on an higher demand than provided by the competitors which provide more value (however that is perceived by your clients) than you.

Although more noticeable when using FOSS, note these are things you must mind as well even if everything you offered was your own proprietary code. You may have built an acceptable blog software, but a competitor using Wordpress (and thus with less investing) might be providing a service as good or better than yours.

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.