A lot of posts on this blog attempt to explain WordPress concepts and terminology, or at least those that are relevant to the post. And the WordPress Codex does a great job of explaining the concepts used by WordPress.

But following lots of questions I’ve seen in comments on posts asking for definitions and explanations, I thought it would be useful to create a jargon buster for WordPress users and developers.

So in this post I’ll attempt to define and explain some of the key concepts in WordPress. Some of these are more relevant for users, others for developers, and some for both.

I’m going to take each term alphabetically, so you can find them easily if you don’t know where they fit in terms of context. But first here’s a list of the terms I’ll define, broken down by broad topic:

I realize this isn’t an exhaustive list of WordPress terminology and that if you’re an advanced developer (or hoping to become one) there may be things I’ve missed out. But this should cover the vast majority of questions that most of our readers ask.

Action Hook

An action hook is a line of code added to a WordPress core file, a theme or plugin which lets you insert extra code by attaching a function to it.

To add an action hook to your theme or plugin, you add this code:

And then to run a function called myfunction at that point in the code, you attach it to the hook using add_action:

If you want to add code which can be overridden or altered with a function (instead of creating an empty spot for code to be added), you use a filter hook.

API

API stands for Application Programming Interface. It’s a codebase that lets you interact with one system from another system.

An API can let you interact with one part of a system from another part of the same system, or it can let you do so from an external system. An example of the first is the Widgets API, which lets you write plugins to create widgets, while an example of the second is the WordPress REST API, or the Google Maps API which you might use if you’re coding a mapping plugin.

Attachment

An attachment is a file that you upload to a page or post on your site. It could be an image, video, or audio clip that you embed in your content, or it could be a file that is accessed by a clickable link that WordPress creates when you upload the file.

Attachment is a post type in WordPress: it’s one of the post types that comes with WordPress out of the box.

Capability

A capability lets a user perform a given action, such as editing posts (edit_posts) or installing plugins (install_plugins).

Each user role has a defined set of capabilities assigned to it, which define what some with that role can do. You can add or remove capabilities from roles using the add_cap() and remove_cap() functions.

Category

Category is an in-built taxonomy that comes with WordPress, that you can use to classify your posts. Categories are hierarchical, which means they can have parent and child categories.

category editing screen
Add categories to structure your site’s content

Categories tend to be used for sections of the site or major themes or topics, as against tags which you generally use more of. In most sites the difference is that you would use categories to structure your site, adding them to the navigation menu, which you wouldn’t with tags. Each category you define is a term in the ‘category’ taxonomy.

Class

A class is a type of programming used in Object Oriented PHP. Using a class instead of a load of separate functions makes your code cleaner and easier to extend.

A class will contain a number of related functions (known as methods): for example, the WP_Widget class includes functions to populate the widget, to save what’s input into it and to output it on the site. You can then write a new class in a plugin or theme that extends the original class by amending or adding to specific parts of it, saving you from having to rewrite the whole thing.

Child Theme

A child theme is a theme which you use to add extra code to a parent theme. If you want to edit a theme you’ve bought or installed from the theme directory you should always use a child theme to do this, instead of editing the theme directly. This is because any changes you make to the theme will be lost when it’s updated.

To tell WordPress that a theme is a child theme, you add extra code to the theme stylesheet with details of the parent theme. Child themes can be used to add tweaks to a parent theme, to make significant customizations, to add extra styling, functions or template files, or in conjunction with a theme framework.

CMS

A CMS, or Content Management System, is a system that lets users add content to a website without having to directly code that content into web pages. WordPress is the world’s most popular CMS!

A CMS needs a database to store content and then a set of files (in WordPress, a theme) which will be used to output that content into a web page, generating front-end languages like HTML and JavaScript. It will normally use a back-end programming language like PHP to do this.

Config File

The config file, or wp-config.php, defines how your WordPress installation is configured. It’s sometimes edited by WordPress itself as you make changes in the admin screens, or you can edit it directly (with care!). Use it to activate Multisite or to turn debugging on or off.

Customizer

The WordPress Customizer is an interface that lets you make changes to the parts of your site that you can’t edit via the post editor. Exactly what features you have access to will depend on your theme (and sometimes plugins), but there are some default elements including widgets, menus, and site identity. Your theme might then also let you customize the layout and colors and add text in the header and/or footer.

The WordPress Customizer
The Customizer makes it easy for you to customize your site in real time

All themes submitted to the theme directory are now required to use the Customizer instead of theme options screens. The advantage of this is that users can see the changes they’re making as they make them. To add Customizer functionality to your own themes, follow our guide.

Custom Field

Custom field is another way of describing post metadata. Use custom fields to add extra data to your posts such as your mood when you were writing, the weather etc. You shouldn’t use custom fields to classify your posts: use categories or tags instead.

To add custom fields, use the interface on the post editing screen. Alternatively, you can create your own metabox to make custom fields even easier to work with.

Database

The database stores all of the data relating to your WordPress installation. This will include content (posts, pages, attachments etc.), user data and options such as configurations you’ve made to plugins.

The database consists of eleven tables. If your site is a Multisite network there will be extra tables for each site, although user data is shared across the whole network in two tables: wp_users and wp_usermeta.

You should never edit the database directly: instead, use the WordPress admin screens to make changes.

Database Table

A table in the WordPress database holds a specific kind of data. For example, wp_posts holds data relating to posts (which includes all post types, not just Posts). There are also tables for taxonomy terms, for options and for metadata such as post metadata.

Filter Hook

A filter hook is coded into a WordPress core file or a theme or plugin. It encloses default code which you can then override by writing a function and attaching it that hook.

To add a filter to your theme or plugin, you use code something like this:

Then if you want to change that default code or text, you write a function with the new content and hook it to the filter like so:

You can also hook functions to filter hooks provided by WordPress, to override default code.

The difference between a filter hook and an action hook is that an action hook is empty: code is only added to it when a function is hooked to it. A filter hook is not empty: it’s wrapped around default text or code that will be output if no function is attached to the hook.

Function

A function is a block of code that you write into your theme or plugin to make something happen. WordPress core files also contain hundreds of functions.

You can make use of core WordPress functions in your own code or you can write your own: it’s always a good idea to check that there isn’t already one that does what you need before you start to create a new one.

You can write a function inside another one: it’s common to write your own function which contains one or more WordPress functions.

To get a function to fire, you can write it directly into a theme or plugin file, in which case it will fire at that point in your file. Alternatively, you can hook it to an action hook or filter hook. The advantage of doing this is that you can insert the function at multiple points in your code or you can override or remove it at a later stage without having to edit the theme or plugin files. This is good practice if you’re developing themes or plugins for others to use and makes them extendable.

To code a function you give it a unique name followed by brackets (inside which you can optionally add parameters) and then add the function code inside curly braces:

Functions File

The functions file (functions.php) is a file in a theme that doesn’t display content on pages. Instead, you use it to add functionality to your theme. The functions file will include things like adding Customizer support, featured image support and any custom functions you add to your theme. A theme doesn’t have to have a functions file to work.

If you find yourself adding too much functionality via the functions file, you might be better off writing  a plugin instead. Plugins should be used for functionality and themes for display.

Include File

An include file is a file you add to a plugin (or sometimes a theme) to hold code separately from the main plugin file. It can be useful to do this when adding a large amount of code to add specific functionality. For example, I would use an include file to add Customizer support to a theme.

To include your file, use a function (such as include_once()) inside your main plugin file or your theme’s functions file to call the include file. This inserts the code from the file in the place where you added the include function.

Loop

The loop is the code in your theme that queries the database and fetches and outputs the current post. For a single post or a page it will run once while on an archive page it will loop repeatedly until all relevant posts have been output.

You can either add the loop to your theme template files or to a template part, which means you can use the same loop in multiple template files. For a guide on how to do this, see our post on theme development.

Meta Box

A meta box is an area in an admin screen that you use to add content, configure settings, or perform an action. You can add meta boxes by writing your own plugins.

The Add More metabox lets users add metadata to this post.
The Add More metabox lets users add metadata to this post.

Meta boxes are incredibly useful as they give users the flexibility to add extra content areas (using metadata) or configurations without having to leave the post-editing screen or write any code.

Metadata

Metadata is data about data. Yes, that sounds ridiculous I know. Let me explain it with an example.

WordPress stores posts (and pages, attachments etc.) in the wp_posts table in the database. Fields in this table are limited to a predefined list including the post title, post content, date it was created,  its status and excerpt.

But what if you want to add extra data to your post that isn’t covered by one of those fields? That’s when you need metadata, sometimes referred to as custom fields. This can be anything you want, from the weather when you created the post to data relating to its SEO.

To create and work with metadata, see our guide.

Method

A method is something that’s used in Object-Oriented Programming. It’s how you describe a function that’s used inside a class. Nothing mysterious about it!

Multisite Network

A Multisite network is a network of sites sharing one WordPress installation. By activating Multisite you can host as many sites on your WordPress installation as you need, from two to millions. For full guidance on installing and managing a Multisite network, see our ultimate guide to Multisite.

The navigation menu is a menu you place in your site’s header to help people navigate around your site. Menu items are a post type in WordPress, and you add them via the menus admin screen or the Customizer.

You can also add extra navigation menus by coding them into your theme or using a widget.

Nonce Keys

NONCE stands for Number used ONCE. It’s a number that can only be used once, normally within a URL. So, for example, if someone attempts to reset their password in WordPress they will be sent a link that includes a nonce. Once they’ve clicked on that link they can’t use it again. This means that someone else can’t use the same link to change their password again.

Use nonces to make your code more secure, for example when saving data via a plugin.

Object

In Object-Oriented Programming, an object is a bundle of variables and related methods. Use them in classes to group functions together and make your code more efficient and easer to extend.

Object-Oriented Programming

Object-Oriented Programming is a programming method that uses objects, methods and classes to group code together and make it easier to extend. This is in contrast to functional programming which treats functions as separate entities.

Options

An option is something you can change about your WordPress site that isn’t part of a post, page or any other content type. Instead, it relates to the site settings or plugin or theme configuration. Options are also referred to as settings.

All of your site’s options are stored in the wp_options table in the database, the only table not linked to any other tables.

Page

A page is a post type that comes as default with a standard WordPress installation. Use it for static content that you don’t need to list in your blog page or elsewhere on the site. Frequent uses include the home page, an ‘About’ page or a contact page.

Some sites are based entirely around pages instead of posts. These often use a hierarchical structure, with parent and child pages.

Plugin

A plugin is a set of code that adds extra functionality to your WordPress site. This could be as simple as changing the login logo or as complex as adding e-commerce functionality.

You install plugins via the Plugins page in your admin screens. You can either write your own, buy them from a plugin vendor or install them from the plugin directory.

WordPress plugin directory

Remember that plugins are for functionality while themes are for display. So if you find yourself writing a lot of functional code into your theme, you might be better off separating it out into a plugin. This is better practice and means you can use the code again in other sites running different themes.

Post

This is where things can get confusing. A post is a post type, but can also be used to refer to all post types. For users the term ‘Post’ normally means the post type you use to create blog posts, articles, updates etc. For developers it can be used to describe all posts contained in the wp_posts table, including posts, pages and more. Here I’ll focus on the first meaning.

To add a new Post you use the post editing screen in WordPress. Posts are distinct from pages in that they’re listed in archive pages and your main blog page. If you’re a blogger, posts will be the lifeblood of your site.

Post Format

Post format is a taxonomy that you can use to display your posts in different formats. By creating template files for different post formats you can show things like video, quotes, images and text differently.

Post Type

Post types are different types of content that you use for different purposes. WordPress comes with a number of post types available to you by default. These are:

You can also add your own by registering a custom post type. To do this, use the register_post_type() function, which you add to your own function defining the arguments for your post type such as its name and how it behaves.

Many plugins create custom post types for bespoke content such as products for e-commerce sites, forms to add form functionality and galleries for displaying images.

Property

In Object Oriented Programming, a property is a variable you use with methods to store and output data.

Query

WordPress runs a query every time it access the database and fetches content to output. So every page on your site will be populated by a query, which is coded via the loop.

WordPress automatically queries the correct content depending on what’s being viewed. So if you’re looking at a single post, the code in the loop will fetch that post, while if you’re looking at an archive page the loop will run over and over again until it’s output all the posts it needs to on that page.

You can also add custom queries to pages to display extra posts, or you can alter the main query to change what’s displayed. Find out which methods you should (and shouldn’t) use to do this in our guide.

Revision

A revision is a version of a post (or page etc.) that’s stored in the database in case you need to revert to it at a later date. This can be useful if you accidentally delete some content for your post or something else goes wrong.

Post revisions metabox
Post revisions are listed in the post editing screen

WordPress automatically saves revisions for you at set time intervals but you also create a revision every time you update your post or save a draft.

Role

A user role defines what that user is able to do on your site. The default roles that come with WordPress are:

  • Super Admin – can manage a Multisite network of sites (only relevant if Multisite has been activated).
  • Administrator – can manage a single site in a standard WordPress installation or a site within a Multisite network..
  • Editor – can publish and manage posts including other people’s posts. They can’t manage site settings.
  • Author – can write, publish and manage their own posts but no-one else’s.
  • Contributor – can write and manage their own posts but cannot publish them. They submit them for an Editor or Administrator to review and publish.
  • Subscriber – can’t add content but can view content you’ve restricted to subscribers or make comments if that’s restricted too.

Each role has a set of capabilities which define exactly what the user can do. You can edit a user role by adding or removing capabilities, or you can create new roles using the add_role() function.

SALT Keys

SALT keys are added to your wp-config.php file to add a layer of security to your site. These are secret keys without which WordPress won’t work. There are four of them: AUTH_KEY, SECURE_AUTH_KEY, LOGGED_IN_KEY, and NONCE_KEY.

These work by preventing hackers from accessing the cookies that store data about your site (such as login credentials). You should refresh them on a regular basis – roughly every two months. Our security plugin like Defender makes this easy.

Sanitization

Sanitization is the process of cleaning input data before it’s saved. For example, if you add a meta box in the post editing screen with a text box, you use a sanitization function to ensure any text input to it is stored in the correct format.

So if you’re saving an email address, sanitization will ensure that it’s stored correctly and will come out of the database as an email address when it’s output elsewhere.

Sanitisation follows validation, which is about checking that inputs have been entered correctly.

Settings

Settings are the configurations you make to your site or to plugins to get them working the way you want them to. There are a number of settings screens in WordPress, and plugins and themes may add their own settings screens too (although a modern theme is more likely to use the Customizer).

You access your site settings screens via the Settings menu in the admin. They’re also referred to as options.

Shortcode

A shortcode is some text inside square brackets that you add to your posts, which then outputs or runs some code. Shortcodes can enclose text you add ([myshortcode]Enclosed text[/myshortcode]), they can stand alone ([myshortcode]), or they can have parameters ([myshortcode number=”10″]).

To create your own shortcodes, write a plugin using the Shortcode API.

Stylesheet

The stylesheet is a theme file which includes all of the CSS styling for the theme. It also contains essential information on the theme such as its name, author and version. It’s one of the two files every theme must contain.

Tag

Tag is a built-in taxonomy within WordPress. Use it to identify posts on specific topics, in more detail than you would with categories. You wouldn’t normally use tags to structure your site but instead you’d use a tag cloud widget to let visitors find posts with a given tag.

Tags aren’t hierarchical so they can’t have parent or child tags.

Taxonomy

A taxonomy is a classification of your posts (of whatever post type). WordPress comes with four built-in taxonomies:

You can also add your own custom taxonomies, which you can apply to existing post types such as posts, pages our attachments, or to new custom post types that you register. You do this using the register_taxonomy() function.

Taxonomies can behave in different ways. Some (e.g. categories) are hierarchical, so each taxonomy term can have a parent. Others (e.g. tags) are non-hierarchical so their terms are in a flat structure. When you register a taxonomy you can specify whether or not it’s hierarchical.

Template File

A template file is a file within your theme that’s used to output content on a page of your site. Every theme must include one template file: index.php. Most themes also include template files for specific content types, like page.php, archive.php and single.php.

WordPress decides which template file to use to display content on a given page according to the template hierarchy.

Template Hierarchy

The template hierarchy is the system WordPress uses to identify which template file to use when displaying a given page on a site. Some template files are more specific to individual content types than others: WordPress will work through them in descending order of specificity until it finds one in your theme. This means that if your them doesn’t have a template file for a specific content type, it will fall back to a more generic file, ultimately defaulting to index.php.

WordPress template hierarchy
The WordPress template hierarchy

So, for example, if you open the archive of all posts with the term dog in a taxonomy called animal, WordPress will work through the template hierarchy in this order, using the file it finds first:

  1. taxonomy-animal-dog.php
  2. taxonomy-animal.php
  3. taxonomy.php
  4. archive.php
  5. index.php

Template Part

A template part is a theme file that contains the code for just one part of a template file. You use this to store code that you want to use in multiple template files, such as the header (header.php), sidebar (sidebar.php) and footer (footer.php). You can call each of these with get_header(), get_sidebar() and get_footer() respectively, in your template files.

You can also use a template part in other places in a template file, for example to pull in the code for the loop. To do this you use the get_template_part() function. Doing this makes your code more efficient as you’re not repeating the same code in multiple template files.

Template Tag

A template tag is a kind of function designed to be used in theme template files. It often fetches and displays data, such as the site name or description.

Term

A term is an item in a taxonomy. So if you’ve added some categories to your posts, each of those categories is a term in the category taxonomy.

You can add taxonomy terms by going to the taxonomy editing screen (e.g. Posts > Categories) or by adding them when you’re editing a post.

Theme

A theme is a set of files that WordPress uses to output content. It will always include at least two files: style.css and index.php. The stylesheet is necessary as it includes essential information about the theme and also adds styling to your site. The index.php file includes code such as the loop which is used to fetch data from the database and display it on the page, plus template tags and other functions which will output other data and media as well as adding interactions.

Most themes include plenty more files: the header.php, sidebar.php and footer.php template parts which output parts of the page that are common to every page, plus other template files for specific content types such as archives, pages and single posts. WordPress chooses which one to use with reference to the template hierarchy.

Widget

A widget is something you can add to a widget area in your site (e.g. in the sidebar or footer) without writing any code. You can do this by going to Appearance > Widgets in the admin or via the Customizer.

customizer - editing widgets
You can edit widgets in the Customizer

Validation

Validation is the process of checking that data is valid before it’s saved to the database. You add validation functions whenever you’re coding some sort of input such as a text box.

For example, if the user is required to input an email address, validation will check that it looks like an email address, i.e. that it’s in the correct format. If it isn’t, it won’t be accepted and the user will see an error message. Once data is validated it should be sanitized.

Is That Everything?

WordPress has hundreds of terms that you may or may not need to get to trips with depending on how you’re using it. Here I’ve tried to include everything that the majority of people will need to know.

If there’s anything that’s stumped you leave a note in the comments and if enough people ask for something I’ll add a definition!

Have I missed something? Is there some WordPress jargon that makes no sense to you? Let us know in the comments (and add your own definitions too).

Tags: