A practical PHP course

Learn PHP by running real code — 25 free lessons

Strings, arrays, functions and classes in modern PHP 8. Write real PHP, run it, and see the output straight away, with nothing to install.

Your pace. Your next step.

Make room for understanding.

Build dynamic web applications with modern PHP 8+. Learn named arguments, fibers, enums, and Laravel fundamentals through hands-on exercises and a free code playground.

Read something useful

Explore the complete course below. Every lesson is free to read, share, and revisit.

Think it through

Predict what happens, put a solution in order, or spot a bug. Short sessions work on your phone.

Make it your own

Open the Code lab when you have a keyboard handy. Run real code and see your ideas take shape.

Try the PHP playground

All PHP Lessons

Browse the complete ordered curriculum. Each lesson has a readable page you can link to and share.

Frequently Asked Questions

Can I learn PHP here for free?
Yes. LearningPHP.org is free, and between the lessons and the browser playground you can work through PHP 8 syntax, arrays, OOP, forms, databases, APIs, and the patterns used in modern web development.
Do I need XAMPP or a local server first?
No. Start by running PHP straight in the online playground, and only set up a local server or framework once you actually want to build something bigger.
Is this modern PHP or the old stuff?
Modern PHP. The course is built around PHP 8+ and the safer patterns that come with it, covering OOP, Composer, testing, APIs, and practical web development rather than habits from a decade ago.
Where should I go after the PHP basics?
Once variables and functions are second nature, spend your time on arrays, classes, error handling, databases, forms, authentication, Composer, and building REST APIs.