All source code on mkyong.com is licensed under the MIT License.

What That Means
Take any code from this site and use it. Copy it into your project, change it, ship it, sell it. You do not need to ask me first, and you do not owe me anything.
Two things come with that:
- Keep the licence with the code. If you redistribute a substantial chunk of it, ship the full block from The Licence below — the copyright line and everything under it. A
LICENSEfile in your repo, a comment header, or a third-party notices page all count. Pasting a five-line example into your own app is not redistribution; this matters when you are handing on the code itself. - No warranty. The code is given as-is. If it breaks something, that is on you. I test everything before publishing, but I cannot know your setup.
That is the whole deal. The MIT License is one of the shortest and most permissive licenses there is, which is why it is here.
What Is Not Covered
This licence is for the source code — the snippets, the sample files, and the projects on my GitHub.
The articles themselves are a different thing. The writing, the images, and the diagrams are not MIT-licensed. Quote a paragraph and link back if it helps you, but do not republish whole posts.
The Licence
MIT License
Copyright (c) 2008-2026 Mkyong.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Questions
If you are unsure whether something here covers what you want to do, ask me. The answer is almost always yes.