Title: get_author_name
Published: April 25, 2014
Last modified: May 20, 2026

---

# get_author_name( int $auth_id = false ): string

## In this article

 * [Description](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#description)
    - [See also](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#see-also)
 * [Parameters](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#parameters)
 * [Return](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#return)
 * [Source](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#source)
 * [Related](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#related)
 * [Changelog](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#changelog)

[ Back to top](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#wp--skip-link--target)

This function has been deprecated since 2.8.0. Use [get_the_author_meta()](https://developer.wordpress.org/reference/functions/get_the_author_meta/)
instead.

Retrieve the specified author’s preferred display name.

## 󠀁[Description](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#description)󠁿

### 󠀁[See also](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#see-also)󠁿

 * [get_the_author_meta()](https://developer.wordpress.org/reference/functions/get_the_author_meta/)

## 󠀁[Parameters](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#parameters)󠁿

 `$auth_id`intoptional

The ID of the author.

Default:`false`

## 󠀁[Return](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#return)󠁿

 string The author’s display name.

## 󠀁[Source](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#source)󠁿

    ```php
    function get_author_name( $auth_id = false ) {
    	_deprecated_function( __FUNCTION__, '2.8.0', 'get_the_author_meta(\'display_name\')' );
    	return get_the_author_meta('display_name', $auth_id);
    }
    ```

[View all references](https://developer.wordpress.org/reference/files/wp-includes/deprecated.php/)
[View on Trac](https://core.trac.wordpress.org/browser/tags/7.0/src/wp-includes/deprecated.php#L1597)
[View on GitHub](https://github.com/WordPress/wordpress-develop/blob/7.0/src/wp-includes/deprecated.php#L1597-L1600)

## 󠀁[Related](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#related)󠁿

| Uses | Description | 
| [get_the_author_meta()](https://developer.wordpress.org/reference/functions/get_the_author_meta/)`wp-includes/author-template.php` |

Retrieves the requested data of the author of the current post.

  | 
| [_deprecated_function()](https://developer.wordpress.org/reference/functions/_deprecated_function/)`wp-includes/functions.php` |

Marks a function as deprecated and inform when it has been used.

  |

## 󠀁[Changelog](https://developer.wordpress.org/reference/functions/get_author_name/?output_format=md#changelog)󠁿

| Version | Description | 
| [2.8.0](https://developer.wordpress.org/reference/since/2.8.0/) | Deprecated. Use [get_the_author_meta()](https://developer.wordpress.org/reference/functions/get_the_author_meta/)  | 
| [1.0.0](https://developer.wordpress.org/reference/since/1.0.0/) | Introduced. |

## User Contributed Notes

You must [log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Ffunctions%2Fget_author_name%2F)
before being able to contribute a note or feedback.