network_admin_url()WP 3.0.0

Retrieves the URL to the admin panel for the network — many sites management (not for a single blog of the network): /wp-admin/network.

If call this function on single site instalation (not Multisite) the admin_url() function will be called.

Hooks from the function


String. Admin URL link with optional path appended.


network_admin_url( $path, $scheme );
The path to a specific page of the admin. Will be added to the URL.
Default: ''

The Protocol to be used. Can be:

  • http
  • https
  • relative - returns a relative URL (without domain).

Function uses get_site_url(), therefore it also understands all its parameter values.

Default: 'admin', which obeys force_ssl_admin() and is_ssl()



#1 Get the URL to the admin area for the network

$url = network_admin_url();

The result:

Or if SSL is used:

#2 Get the URL to the specific page of the network admin area

This example demonstrates how to add a path and specify the protocol and what the function will return.

In this example we want to get the URL to the «Users - Add new» page, and specify the protocol (scheme) to https.

$url = network_admin_url( 'user-new.php', 'https' );


Since 3.0.0 Introduced.

network_admin_url() code WP 6.4.3

function network_admin_url( $path = '', $scheme = 'admin' ) {
	if ( ! is_multisite() ) {
		return admin_url( $path, $scheme );

	$url = network_site_url( 'wp-admin/network/', $scheme );

	if ( $path && is_string( $path ) ) {
		$url .= ltrim( $path, '/' );

	 * Filters the network admin URL.
	 * @since 3.0.0
	 * @since 5.8.0 The `$scheme` parameter was added.
	 * @param string      $url    The complete network admin URL including scheme and path.
	 * @param string      $path   Path relative to the network admin URL. Blank string if
	 *                            no path is specified.
	 * @param string|null $scheme The scheme to use. Accepts 'http', 'https',
	 *                            'admin', or null. Default is 'admin', which obeys force_ssl_admin() and is_ssl().
	return apply_filters( 'network_admin_url', $url, $path, $scheme );