How Do I Center Text on a Page in WordPress?

WordPress can center text on a page by using the text editor and the wp_page_title() function. To center text in the text editor, use the text editor’s text-align property to center the text.

To center text in the wp_page_title() function, use the wp_page_title() function’s center() parameter. The following code example centers text in the text editor and the wp_page_title() function.

Hello World!

This is a paragraph. It will be centered.

You can also use the text-align property in the text editor to center text in a post or page. You can also use the center() parameter in the wp_page_title() function to center text in a post or page.

The following code example centers text in the text editor and the wp_page_title() function.

This is a paragraph. It will be centered in the text editor and in the wp_page_title() function.

.