MySQL Licenses: The Do’s and Don’ts of Open Source, or What’s All the Fuss About?

MySQL Licenses
The Do’s and Don’ts of Open Source, or What’s All the Fuss About?

copyright ©2010 by
Mark Schonewille and Economy-x-Talk
Nijmegen, the Netherlands
this version: 1.3 (26 Nov. 2010)

1 Introduction

In reply to a question on the LiveCode User Mailing List, I argue that MySQL is one of the best freely available (open-source) databases. A number of subscribers to that mailing list reacted quite strongly, saying that open-source doesn’t mean free. Apparently, they use the word “free” as in “free beer”, while I use it as in “free speech”. They argue that one needs to pay Oracle Corporation a lot of money if one uses MySQL, despite the fact that MySQL is open-source and freely available.

This was enough reason for me to call Oracle Corporation. After 30 minutes of searching for the right person, I was connected to a friendly Oracle Corporation employee. I asked this employee three questions: 1) do I have to pay Oracle Corporation if I use MySQL at home, 2) do I have to pay Oracle Corporation if I make commercial software that works with MySQl and 3) do my customers have to pay Oracle Corporation if they use MySQL in combination with my commercial software? His answer was a resounding and clear threefold “No!”

One doesn’t need to pay Oracle Corporation. It should be clear, though, that MySQL’s license, specifically the GNU General Public License (GPL for short) requires it to stay open-source. The GPL poses a few limitations on the use and distribution of MySQL, but creates opportunities at the same time.
In the text below, I explain the implications of the GPL for users of MySQL. In doing so, I will discuss a number of typical examples.

2 Unpaid Without Redistribution

You can freely download the MySQL software from the website . You can install it on your laptop for your own personal use, to test your website with a MySQL server. You can upload those websites to a web hosting server. You don’t need to pay Oracle Corporation anything in this situation.

A web hosting company can offer the MySQL database engine as an extra service on their servers. They can freely download the MySQL database engine from the MySQL website and they don’t need to pay for it. The customers of the web hosting company also don’t need to pay for using MySQL with their websites.

As another example, a printing company wants to manage a large customer database and has MySQL installed on an internal (local) server after downloading it from the MySQL website. The printing company is allowed to use the MySQL database for free without paying Oracle. The same company can ask me to make software for them, which will talk to their MySQL database. That company still doesn’t need to pay Oracle Corporation and I myself don’t need to pay either.

In a third example, I make commercial software, which needs to have MySQL installed. My customers can use my commercial software, for which they do need to buy a license, in combination with the MySQL database engine, for which they don’t need to pay. Because the MySQL engine is not embedded in my commercial software and I don’t redistribute MySQL together with my software, I don’t need a commercial license for MySQL and neither do my customers.

The next situation is a little tricky. I make commercial software and need a special version of MySQL to make it work. I adjust the MySQL engine and distribute it as open source software. I offer the source code for free to everyone who uses my adjusted MySQL database engine. I simultaneously distribute my commercial software accompanied by a note that it needs the adjusted version of MySQL. I make sure that the original GPL applies to my customised version of MySQL. I tell my customers to install my version of MySQL on their servers and to install my software on their client machines. I don’t need to pay Oracle Corporation because I distribute the adjusted version of MySQL under the GPL and it is not embedded in my commercial product.

This is about as far as you can stretch the GPL. In the situations described in the above, I don’t act as an OEM (Original Equipment Manufacturer), an ISV (Independent Software Vendor) or a VAR (Value Added Reseller) and I, my customers and my (internet) service provider can use MySQL without paying Oracle. (Note that redistributors are not limited to OEM’s, VAR’s and ISV’s only).

3 Redistributing the MySQL Software

The next step would be to adjust the MySQL engine in such a way that it can work with my commercial software product without distributing the code for the adjusted engine. This causes a dependency between the MySQL software and my commercial product and violates the GPL directly. The GPL can no longer apply and I will need to buy a commercial license from Oracle Corporation in this case.

I could download the MySQL engine and embed it into my product, e.g., by letting my installer install MySQL automatically together with my own product. I don’t want to disclose the source code of my entire product. Because I am selling my commercial software product together with the embedded MySQL engine, I have become an ISV and I need to buy a special commercial license to do so.

It should be obvious that I also need to buy a commercial license, if I want to use the MySQL source code libraries, rather than compiled binaries, in the source code of a commercial product without revealing the source code. Selling this commercial product violates the GPL and requires that I pay Oracle for a license.

However… as long as I have no desire to sell the embedded MySQL source code commercially, I can let the GPL license apply. For example, if the aforementioned printing firm asks me to create an in-house tool to manage their database, they might require that the tool includes the MySQL server (either by embedding the source code into mine or by combining the binary with the final product). If I make the tool, include MySQL in it and license it to the customer under the GPL, my customer has no obligation to reveal the source code to anyone, as long as he doesn’t redistribute my work. The customer still doesn’t need to pay Oracle Corporation for a MySQL license, nor do I.

However (again)… I have to offer my customer the source code as required by the GPL. If the customer doesn’t want the source code, I don’t need to give it to him. If the customer wants to redistribute the product, he needs to ask me for the source code, because he has to make the same offer to those who receive the redistributed software from my customer as I had to.

The interesting point here is that my customer still can (or rather has to) pay me for my services. I made the software for him and he already agreed to pay me for my efforts. When he redistributes the software under the GPL, he can offer his own customers a similar service.

4 Then What’s All the Fuss About?

It is quite obvious that Oracle Corporation doesn’t write on the MySQL website “please don’t pay us”. However, the goal of MySQL isn’t only to generate money. By supporting MySQL, Oracle Corporation makes sure that a large community of software and database developers continues to exist. This community creates new ideas that Oracle Corporation might use —reverse engineer, if you want— in their commercial products. Another reason to support MySQL is that some customers might prefer the commercial Oracle database over the non-commercial MySQL database at some point.

If you decide to pay for a MySQL license, you don’t actually pay for the software. The software is open-source after all and can’t be sold without offering the source code. If Oracle Corporation would ask loads of money for the software only, someone would decide to compile the binaries and offer them for free, together with the source code. Anyone could do so.

Also, Oracle Corporation can do exactly the same as you and me: sell a service connected to MySQL. Oracle Corporation provides support to anyone who wants to pay for it. This way, MySQL is a source of revenue for Oracle Corporation.

Finally, there are the licenses for OEM’s, VAR’s and ISV’s. Everyone who wants to sell MySQL software as part of their proprietary software or hardware product needs to buy a commercial license. This is another source of revenue for Oracle Corporation.

For most small businesses, MySQL is the least expensive (or even completely free) and often the most efficient database available, provided that they don’t need support from Oracle Corporation. For example, being a small company with all necessary skills available in-house and not having huge databases that require continuous monitoring, Economy-x-Talk doesn’t need to buy support from Oracle Corporation.

5 Conclusion: Redistribution Is Key

The conclusion of this story is twofold. First of all, as long as you don’t redistribute the MySQL software, you don’t need to worry about licenses, even if you make money by providing database-related services or products that need MySQL to be available. Second, even if you redistribute MySQL under the GPL, you can still make money with it, as long as you offer the source code of your project, which your customer might not even want to have.

To clarify the second conclusion, keep in mind that it is not obligatory to redistribute your compiled software. When you offer the source code, your customers are not obliged to accept the offer. Because you are the one who provides the service of maintaining and improving the software and your customers are actually already paying you for this service, they might not care about the source code. Only if you ever decide to stop providing this service, your customer might have an interest in the source code.

Oracle Corporation seems to stick not closely, but completely, even literally, to the GPL. All the fuss about Oracle Corporation no longer supporting MySQL and not caring about small companies who use the MySQL database engine is sheer nonsense. Oracle Corporation continues to support MySQL for now. Even if they decided to terminate their support, anyone could take the MySQL engine and continue to develop and redistribute it under the GPL.


Please, feel free to comment on this article. Keep in mind, however, that I asked Oracle Corporation for their opinion on this matter and, although not in as many words and not that specific, this was their answer. I would like to thank Björnke von Gierke and Judy Perry for their comments.

The author owns the software development company Economy-x-Talk and gladly offers his services. Need help with LiveCode, PHP or MySQL? Let me know

The author accepts no responsibility for any consequences of business decisions based on this information. It is the reader’s responsibility to read the actual license conditions on Oracle Corporation’s MySQL website and consult with Oracle Corporation if in doubt. This article represents the personal opinion of the author, is not endorsed by RunRev Ltd. and has not been authorised by Oracle Corporation.

Integral reprint in physical and electronic form is herewith granted, on the condition that the copyright notice, the version number, the date, the URL’s and this sentence are included. If you publish this text on a web site, please embed the URL’s in a sensiblel way.

21 thoughts on “MySQL Licenses: The Do’s and Don’ts of Open Source, or What’s All the Fuss About?

  1. Giuseppe Maxia

    (Q) If a library is released under the GPL (not the LGPL), does that mean that any program which uses it has to be under the GPL or a GPL-compatible license? – (A) Yes, because the program as it is actually run includes the library.

  2. Giuseppe Maxia

    Actually, it was a long and elaborate comment, but only one small piece was saved. That Q&A is from the GPL FAQ

  3. KBS

    Can you comment on the ConnectorJ JDBC driver? Or other commercial or GPL drivers needed to access data in a commercial or GPL MySQL database. What license is needed in the above situations for database drivers?

  4. Mark Schonewille

    I can’t comment on specific database drivers. Most of the time, you can offer your customer a custom software package that includes open-source software. You can combine many types of open-source software under different licenses.If you are offering a generic commercial product, then you can’t always include everything. MySQL allows you to do this, as long as you also provide the source code of the product. Some database drivers may not allow you to exploit them commercially. An example of a product that lets you almost completely free in how you offer the product is SQLite. You really need to read the license conditions and decide whether or not the product is feasible for inclusion in your own project.If you are creating your own commercial database driver, then you can include it in your commercial product and tell your customers to install MySQL separately. Since your product needs MySQL but you don’t include it in your product, you won’t need to provide the source code. Just keep in mind, I’m not a legal expert. I just took the time to read the GPL.

  5. Kamran

    MySQL’s licensing(thanks to Oracle) is a bit of grey area. Oracle wants to you buy a commercial license if you are developing an application for a client or for commercial use. All the mysql connectors are GPL licensed as well. I don’t know why is MySQL so popular with all this legal blur. Thats one of the reasons (in addition to a lot of technical ones) why I prefer PostgreSQL over any other open source database. I also hate the use of GPL for such commercially viable projects for which more permissive licenses like ASL, MIT and BSD are more suited.

  6. Mark Schonewille

    I’m afraid that responses like those do more bad than good. It is very easy to confuse people on this subject. MySQL can be used for commercial projects without pay for it, as long as you also offer to deliver the source code together with the compiled code. The customers doesn’t actually have to accept this offer, but you need to make the offer. That’s it. Surely, the PostGreSql license is more liberal (it basically says you can do anything you want as long as you include the official copyright notice and license text) but many web host offer MySQL and no PostGreSql. Many people don’t make their decision which database to use based on the license but rather on what is available. If you’re forced to use MySQL, then it is good to understand that you don’t need to get a commercial license under any circumstance, unless you want support from Oracle.

  7. Louis

    The hardware from Everyone who wants to sell MySQL software as part of their proprietary software or hardware product needs to buy a commercial license confuses me. Basically if one sells an embedded device with a MySQL server running on it, how it is different than selling an embedded device running the Linux kernel. It’s a GPL license in both cases. Seems like Oracle’s dual licensing scheme allows, not prevents the users from doing things. Still I feel like I’m missing something. I don’t understand how Oracle managed to achieve this in the first place with what used to be a GPL software. How is it different than deciding as an individual to redistribute the Linux kernel under the same dual licensing scheme and then having somebody to pay me to be allowed to sell a modified Linux kernel without distributing the modified sources?

  8. Alberto Cherubini

    If one does a plugin in .NET, which links the .NET MySQL connector and builds as a dll, does one need to buy an ISV licence? probably yes if the source code of the plugin is not open, but probably not if it is open source?
    Am going to ask Oracle as well.

    1. marksch Post author

      ISV is a Microsoft term, not an Orcale term. Oracle calls it a dual license (which is correct). If you’re hard-linking, you need a dual license. This costs at least $ 2000. I don’t know which edition of MySQL you’d need exactly. If you’re soft-linking, you may not need anything. You could just tell your users to install MySQL.

  9. Kaje

    For example, If I’m selling the value added hardware (I buy a server hardware and install mysql with my own application which uses mysql and sell it to my customers), Do I have to pay for Oracle?

    1. marksch Post author

      The question is not whether you have to pay. The question is whether you have to disclose your source code. If you sell hardware together with your own software and install MySQL manually as an extra service to your customer, you don’t need to disclose your own source code. The arguments are 1) you don’t deliver MySQL as an integrated part of your software and thus you don’t need to reveal the source code of your software and 2) you could tell the customer to download and install MySQL by himself while selling your own hardware and software to him. In short: you’re not redistributing MySQL and thus you don’t need to disclose your source code.

  10. Sunil

    A small medicine store is in need of a software to computerize whole store (medicine stock, sale, profit, computerize billing).

    I can make this by using MySQL.

    I want to earn my work’s reward.

    Can I sell that software program to my medicien store client without paying anthing to Oracle ?

    1. marksch Post author

      Please, have a look at my answers to other questions. I can’t comment on every individual case. Just keep in mind that you don’t need to pay for a license of your project is open-source, if you don’t actually include the MySQL source code in your project (hard-linking), and don’t need support from Oracle.

  11. Jens Meier


    thank you for this great article! Could you please help me with the question “Do I have to buy I license?”?

    – I develop und sell an commercial closed source application which connects to a mysql server
    – I use a 3rd party mysql connector (from devart)
    – I don’t change anything in the mysql server source
    – Each customer needs a mysql server in his network. Does is make a difference if I download and install the mysql server on the customers system (is this called “distributing”?”) or the customer download the mysql server himself?

    Best regards


    1. marksch Post author

      Jens, if you install MySQL on the customers’ systems as an extra server but don’t sell MySQL to them as part of your product, I would think you don’t need to buy a license for MySQL. Your customers might as well install MySQL by themselves and all you do is save them a little work. Note that it might be a different (but not necessarily so) if you automate the entire process and install MySQL as part of your commercial product.

      1. Luis Ramos

        So as the same question of Jens. It wasn’t clear about the connector for MySQL. Same situation of a closed-source application that will use a MySQL connector. MySQL will not be a part of the software (embedded) and I don’t pretend to redistribute or modify MySQL. I just want to develop my closed application and deploy it into MySQL (views and stored procs) using my own server or a cloud service, and as you said marksch, I or someone else could install MySQL. If I just want to make available my application on Internet in order to give an online service as Facebook does, I think I don’t need a commercial license of MySQL, isn’t it? Am I right or wrong? Thanks for this valuable article. It clarified many preconceptions about GPL and MySQL.

        1. marksch Post author

          I can’t respond to every individual case. I also can’t take responsibility for the decisions based on this information. Please, take into consideration the issues discussed in the article and the comments made so far. I hope this will help you to make the right decision.

  12. erose

    If our company sell my system (which by the way used MySQL as its database) to a client, do my client need to purchase MySQL (standard or enterprise edition)?? Or they can use MySQL Community edition for free?

    And as an inhouse developer of our company, after the development stage. do the company have to purchase and use the MySQL (standard or enterprise edition) to use my developed system?? Or we can use MySQL Community Edition for free?

    A response will be highly appreciated!


Leave a Reply

Your email address will not be published. Required fields are marked *