Tables are an easy way to represent important data and almost all websites online will use some kind of table. WordPress, being an important tool for creating websites has several ways in which you can insert tables to your pages and posts.
How can I create a table in WordPress?
The easiest way to create and add tables to WordPress pages and posts is to install a WordPress table plugin. There are several advantages to using a WordPress table plugin.
There are also other ways to add tables to pages without using table plugins which we will cover in this article.
Create tables with a WordPress table plugin
In WordPress there are several WordPress table plugins available.
In the article, we will use a table plugin called Tablesome. It is a versatile WordPress table plugin with which you can create any kind of table and the best part is that it is fully free.
You can check out all the features of Tablesome and see demo tables before using it.
Installing a WordPress Tablesome plugin:
- On your WordPress dashboard go to Plugins → Add New → Search “Tablesome”
- Install and activate the Tablesome table plugin.
- Then click ‘Add New’
- In the Create New Table page add the table content to this page.
You can also import table data from CSV and XLSX files if you have them.You can make use of the different formats for each column such as TextArea, Numbers, Email, Image, URL, Date, etc,. This would be helpful if you want to make use of table options such as Sorting and Filtering.
- After adding all the content click ‘Save Table’. After your table is saved you will be provided with a unique table shortcode with an ID.
- Copy the shortcode and paste it on any page or post where you want to embed the table.
Customizing Table Display in Tablesome
Pasting the table shortcode will add the table to the page or post with all of the table options. You can customize your tables Globally (how all the tables in your site are displayed) on the Tablesome Settings page.
- To do this, on your WordPress dashboard go to Tablesome → Tablesome Settings → General
- Here you can change the settings for all the table options including Pagination, Search, Sort, Filters, and Table Layout Options
- Then go to the ‘Style’ tab on this settings page. Here you can Enable/Disable custom styling for the tables
- When custom styling is enabled you can change the style of Headers and Table Content including the borders, background color, and font styles.
Customizing Individual Tables with Shortcode Builder
The options in the Tablesome Settings page are applied globally. You might want to customize the display of individual tables. So Tablesome provides you with a unique Shortcode Builder with which you can customize the display of individual tables.
Tablesome Shortcode Builder can be used on any editors including Classic, Gutenberg, and Page Builders.
In Classic Editor you can find a “Add Tablesome Shortcode” button and in Gutenberg editor, you can find a “Add Tablesome Shortcode” block.
- Go to the page on which you want to add the table. Find the “Add Tablesome Shortcode” block/button and click it.
- It will open a page as a pop-up. On this page, paste the Table ID No., that you will find on the shortcode.
- Then choose the necessary table options that you need for your table. You could also hide some table columns if you want.
- Then click the “Insert Shortcode” button and the customized Tablesome shortcode will be pasted on your page.
- Then Publish/Update your page and you can find your table published on the page.
Adding tables to pages and posts without plugins
Can you create tables in WordPress without using plugins? Yes, it is very much possible.
There are 2 ways in which you can do this.
1. Using WP Table Block
If you are using the Gutenberg editor you can make use of the WP Table Block to add tables to your page or post.
One important issue with this table is that you need to give the correct number of rows and columns before creating the table. You cannot add more rows and columns after you create the table. So it can be a little frustrating.
2. Using online HTML Table Generator tools
Various online HTML Table Generator tools are available online which you can use to generate tables and embed tables on the page. For example, you can check out this table generator tool.
After generating the table HTML paste in the HTML block or in the Text Tab if you’re using Classic editor.
The most troublesome problem with this method is that after you generate and copy the HTML if you close the tab of the Table Generator tool your data will be lost. If you want to edit the table, you will have to start from the beginning. Your data will not be saved on the tool.
Limitations of tables created without table plugins
- Not responsive – More and more internet users are browsing from their mobile devices. So it is better to use table plugins that provide be
- Theme compatibility – HTML and WP Block tables may not look well in all WordPress themes.
- Takes a lot of time – You have to manually enter table data into each table cell, which tables a lot of time. When you use a table plugin you can easily import large data from Excel and other spreadsheet tools. Table plugins also help you to easily export table data.
- Lack of DataTable options – When you have a DataTable, options such as table Sort, Search, Filter, Pagination, etc., would be very useful for users who want to find the needed information. These table options would be freely provided by the Tablesome table plugin.