How to Write a WordPress Plugin: 12 Essential Guides and Resources

Want to learn how to extend WordPress? Consider this a crash course resource for building your own plugin. WordPress plugin development requires a little bit of personal initiative. Get ready to jump in and teach yourself. But where should you start? We’ve prepared a list of the most essential resources for those who are new to writing plugins.

Creating a Custom WordPress Plugin From Scratch

This tutorial is extremely thorough, beginning with the file structure of a plugin. It walks you through integrating it with actions run by its frame and creating a configuration panel for site administrators. Download the source code and follow along as you build a simple plugin.

View Tutorial

How to Build a WordPress Plugin

In this tutorial you will build a dashboard widget for active plugins, which is a great starting point for learning how to interact with WordPress actions and filters. This tutorial is very much a hands-on experience for building plugins. It’s very well-illustrated and will walk you through each step.

View Tutorial

WordPress Hook Sniffer

WordPress Hook Sniffer is a plugin for plugin developers that helps determine the sequence in which action and filter functions are fired. This tool will save you tons of time once you have a decent understanding of action and filter functions.

Download Plugin

WordPress Hooks, Barbs, and Snags

This tutorial was written by Jeff Jayre, the developer of the WordPress Hook Sniffer. It will help you learn how to interpret the output from the Hook Sniffer so that you can use it more efficiently in plugin development.

View Tutorial

phpxref

phpxref is a resource based on the WordPress trunk. It’s hosted by one of the lead developers for WordPress and is updated every night. Each file included in the trunk has a basic explanation of what it does and will help you to track down how things get executed and called.

View Resource

A Crash Course in WordPress Plugin Development

This tutorial includes a screencast, source code, and a step-by-step guide for creating your first WordPress plugin. It’s very easy to follow and an excellent resource for beginners.

View Tutorial

Advanced and Hidden WordPress APIs by Andrew Nacin

This resource is a collection of the slides from Andrew Nacin’s WordCamp Mid-Atlantic presentation on advanced WordPress APIs. The article links to all of the resources that he recommends in the presentation. You’ll find this resource to be more valuable after you’ve already completed some beginner tutorials.

View Tutorial

WordPress Plugin Development Beginner’s Guide

This book has received excellent reviews. It was written by Vladimir Prelovac, a respected plugin developer. If you learn better by using books, then this resource will be your best bet for learning how to write plugins for WordPress.

View Book

Writing a Plugin – WordPress Codex

The WordPress Codex will always be one of the best resources you have for learning about plugin development. This page will help you to become acquainted with the standard plugin information, licensing, and the basics for programming your plugin. You’ll also find many links to more helpful information that expands upon the each section.

View Codex

Top 10 Most Common Coding Mistakes in WordPress Plugins

This is an excellent article by Ozh that will help you to avoid many of the common pitfalls. If you have already been developing plugins or if you simply want to avoid starting any annoying habits, be sure to check out this article.

View Tutorial

WordPress Hooks Database

The hooks database automatically scans each WP build for apply_filters(), do_action(), and do_action_ref_array to figure out exactly which hooks are available in each version and where the hooks occur. This is very handy when building your own plugins.

View Resource

WordPress Plugin API

The WordPress codex offers a great introduction to Hooks, Actions and Filters. Read this guide after reading the Writing a Plugin section. This is the official documentation of the API (Application Programming Interface) hooks available to WordPress plugin developers.

View Codex

Comments (28)

Participate