PCMag editors select and review products independently. If you buy through affiliate links, we may earn commissions, which help support our testing.

The Best Programs for Learning to Code

We should all learn to code, and no matter your skill level, there's an online school that can teach you how.

Our 9 Top Picks

PCMag Logo
Our Experts Have Tested 20 Products in the Education Category in the Past Year
Since 1982, PCMag has tested and rated thousands of products to help you make better buying decisions. (Read our editorial mission.)

Coding is a critical skill these days, and not just for web developers. Whether you're creating a website, assembling a professional portfolio, or contributing to an online publication, knowing even the basics of coding can go a long way. Of course, if you've ever tried to learn how to code—and we've taken many a course over the years—you know that it can be a frustrating and overwhelming process. Online learning programs can make the education process less intimidating, enabling you to move at your own pace, seek help when you need it, and repeat lessons as needed until you have a real grasp on how and why your code is working the way it does.

We looked at a wide variety of online schools aimed at different age groups and skill sets to find the best coding classes. If you want to learn to code online, these services will put you on the right path. Here's what to look for when making your selection.


Treehouse

Online Coding Costs

Price is always a concern, no matter what you're buying. There are subscription-based programs such, as Code Avengers, Treehouse, CodeHS, and SitePoint (formerly Learnable), that offer access to all classes in the course catalog for a monthly or annual fee. Check to see if the program lets you pause your membership, which is helpful if you want to save your progress without racking up fees while you're away on a trip or too busy to access the classes.

Khan Academy and LinkedIn Learning (formerly Lynda.com) feature classes on every topic under the sun, as do similar general education services not featured here, such as CourseraedX, and Udemy, and there are more than enough coding options to make a subscription or individual purchase worthwhile. If you only care about coding, you might be better served by a program specifically tailored to your needs, especially if you're willing to pay. Safari Books Online and Code School, which we previously covered here, have now been fully absorbed into their parent companies, O'Reilly and Pluralsight, respectively. Those robust, broad, business-oriented education platforms cater toward business teams that want to learn more more tech's benefits in the workforce.

Codecademy, on the other hand, offers many of its courses and materials for free, though it charges a monthly fee if you want to access quizzes and other learning tools. Paid classes generally offer more in the way of course depth, breadth, and presentation, but if you're determined and resourceful, you may find that free classes are sufficient for your needs.


Code Avengers

Course Variety

After price, the most important thing to consider in a coding service is the number (and variety) of offered courses. Some feature HTML, CSS, and other web technologies, while others contain advanced languages (like Python and C++,) mobile app and video game development, and working with APIs. In terms of the sheer number of courses, paid classes usually have the edge over free ones. A huge library can also be overwhelming, so starting with a smaller, focused program is a good option.

The course format is worth paying attention to, as well. All you really need to code is a functional text editor, and most of these programs feature one of those. Depending on your learning style, you might appreciate the polished video tutorials from Khan Academy and LinkedIn Learning.

Many of these online coding schools, including SitePoint, Code Avengers, Codecademy, and Treehouse now offer curriculums, so you can choose a broad topic—like choosing a major in college—and then access all the necessary courses you'll need to master the topic. This organize your studies, and lets you skip ahead if you've already mastered particular skills. Treehouse even offers a structured certification program.


Codecademy

Easy Entry

If you're a beginner, you need a program that's easy to dive into as the material becomes more complex. That's ideal for learners at all levels. You'll also need encouragement to keep you going. Most of these services offer badges or other rewards when you hit milestones and show your progress on your dashboard. The best services offer quizzes and challenges so you can test your skills. Testing isn't just for beginners—even experienced programmers want feedback on how they are doing. Newer programs also like to treat progress like a game, rewarding students with shiny badges as they level up their skills. You won't find these features in all programs, though.

However, if you're serious about pursuing coding as a career, eventually you'll need to ditch the easy stuff and take on some more challenging material. Consider switching to a paid program, such as Code Avengers or Treehouse, to continue your coding education. Free Code Camp will help you take the knowledge you've learned and use it to help start your career at a real-life organization. Google directly offers coding education resources. Alongside their online programs, Coding Dojo and General Assembly host physical campus locations where you can (safely) learn alongside fellow students.


Free Code Camp

Kid-Friendly Lessons

If you're a parent or teacher, getting kids to code makes sense. Programming teaches kids to think logically, develops problem-solving skills, and improves how they interact with technology. Plus, it can prepare them for the workforce of tomorrow. CodeHS has special features educators can use in the classroom, and a wonderful sandbox mode that students can use to express their coding creativity.

CodeCombat and similar programs treat coding more like a video game to help keep kids interested. Coding is just another way to make cool things they can show off, which means kids of any age can learn to code. CodeCombat and Treehouse offer special pricing and curricula for teachers and students. HopscotchScratch, Move the Turtle, Daisy the Dinosaur, and similar apps treat coding like a video game, keeping the interest of even very young kids. With coding, as with any kind of language, the younger you can start learning, the better.

Moving beyond the scope of this particular roundup, GameMaker Studio 2 and other dedicated video game design software go even further with gaming, teaching coding (and animation) as an important part of their game-design curriculums. Licenses are pricey, but the lessons are robust. Plus, the apps teach kids how to make everything from 3D platformers to 2D sidescrollers to products they can offer for sale in PC gaming marketplaces.

If you're an educator interested in other ways technology can help your school, check out our list of the best learning management systems.


SitePoint

Coding Help and Support

You'll need help when you get stuck on an exercise or a quiz. We like Codecademy, Treehouse, and other services that offer active student forums to help you work through problems, and get a second eye on long code blocks. Code Avengers has live chat and an exclusive Slack channel. Support for bugs and website problems, which most of these services offer in some way, is also key. Some communities encourage you to create a GitHub account, so you can easily collaborate on code with fellow students. Although LinkedIn Learning and Khan Academy are excellent generalist services, they can't offer this level of coding-specific help and support.

All these considerations depend on your level of skill. You may not need a lot of handholding, in which case you can download ebooks and teach yourself by signing up with SitePoint, or you can dive right into a new language with Codecademy.

Not sure where to start? Most of the paid services here offer a free or low-cost trial or even a money back guarantee. You may try several online coding classes before you find the right fit. For more, check out The Best Online Learning Courses and Quarantine and Learn: 9 Free Online Courses You Can Take Now.

Our Picks
Codecademy
See It
$0.00
at Codecademy
(Opens in a new window)
Treehouse
See It
$25 Per Month
at Treehouse
(Opens in a new window)
GameMaker Studio 2
See It
at YoYo Games
(Opens in a new window)
Khan Academy
Check Price
(Opens in a new window)
Code Avengers
See It
Starts at $29 Per Month
at Code Avengers
(Opens in a new window)
Free Code Camp
See It
$0.00
at freeCodeCamp
(Opens in a new window)
LinkedIn Learning
Check Price
(Opens in a new window)
SitePoint
See It
Starts at $9 Per Month
at SitePoint
(Opens in a new window)
CodeHS
See It
Starts at $75 Per Month
at CodeHS
(Opens in a new window)
Rating
Editors' Choice
4.0 Editor Review
Editors' Choice
4.0 Editor Review
Editors' Choice
4.5 Editor Review
Editors' Choice
4.5 Editor Review
Starting Price
Free $25 per month $39 per year Free $29 per month Free $19.99 per month $9 per month $75 per month
Free Trial
Free Courses
Video Tutorials
Quizzes
Built-in Tools
User Forums
Where to Buy
$0.00
at Codecademy
 
(Opens in a new window)
$25 Per Month
at Treehouse
 
(Opens in a new window)
 
(Opens in a new window)
Visit Site
at Khan Academy
 
(Opens in a new window)
Starts at $29 Per Month
at Code Avengers
 
(Opens in a new window)
$0.00
at freeCodeCamp
 
(Opens in a new window)
30-Day Free Trial
at LinkedIn Learning
 
(Opens in a new window)
29.99 Per Month
at Linkedin
 
(Opens in a new window)
Starts at $9 Per Month
at SitePoint
 
(Opens in a new window)
Starts at $75 Per Month
at CodeHS
 
(Opens in a new window)
Like What You're Reading?

Sign up for Lab Report to get the latest reviews and top product advice delivered right to your inbox.

This newsletter may contain advertising, deals, or affiliate links. Subscribing to a newsletter indicates your consent to our Terms of Use and Privacy Policy. You may unsubscribe from the newsletters at any time.


Thanks for signing up!

Your subscription has been confirmed. Keep an eye on your inbox!

Sign up for other newsletters

PCMag Stories You’ll Like

About Molly McLaughlin

Molly McLaughlin

Molly K. McLaughlin is a New York-based writer and editor with more than a decade of experience covering technology. She has tested and reviewed all sorts of software, mobile apps, and gadgets. Before launching her freelance business, Molly was an editor at PC Magazine, covering consumer electronics, followed by a stint at ConsumerSearch.com, a review website. She also contributes to Lifewire.com and other online publications.

Read the latest from Molly McLaughlin

About Jordan Minor

Jordan Minor

My Experience

In 2013, I started my Ziff Davis career as an intern on PCMag's Software team. Now, I’m an Analyst on the Apps and Gaming team, and I really just want to use my fancy Northwestern University journalism degree to write about video games. I host The Pop-Off, PCMag's video game show. I was previously the Senior Editor for Geek.com. I’ve also written for The A.V. Club, Kotaku, and Paste Magazine. I’m currently working on a book about the history of video games, and I’m the reason everything you think you know about Street Sharks is a lie.

My Areas of Expertise

The Technology I Use

I use the newest Android and iOS smart phones for testing, but I’m holding onto my original iPhone SE for dear life. You can’t beat that size, and I refuse to give up headphone jacks.

I’ve always favored big, dumb gaming laptops over desktops, and I should really upgrade my aging HP Envy sometime soon. No matter what machine I’m working on, though, an alarming amount of my personal and professional life revolves around cloud-synced Google Drive files.

When it comes to food subscriptions, my household sticks with HelloFresh for meals. Video streaming is a bit more complicated. While there are too many services to list, we’re subscribed to most of the major ones. These days I find myself drawn to HBO Max and the trashy Discovery+, two services that will eventually merge into one.

I’m a lifelong Nintendo fan and I sincerely believe the Nintendo Switch will go down as one of the best gaming consoles of all time. It has an unbelievable library of new and old games from Nintendo and third-party companies. The handheld/console hybrid approach makes playing games so much more flexible that I’m about to fall in love with the concept all over again thanks to Valve’s Steam Deck.

Read the latest from Jordan Minor