diff --git src/wp-includes/taxonomy.php src/wp-includes/taxonomy.php
index e0acadcf87..31558d9898 100644
--- src/wp-includes/taxonomy.php
+++ src/wp-includes/taxonomy.php
@@ -506,6 +506,11 @@ function unregister_taxonomy( $taxonomy ) {
 	$taxonomy_object->remove_rewrite_rules();
 	$taxonomy_object->remove_hooks();
 
+	// Remove custom taxonomy default term option.
+	if ( ! empty( $taxonomy_object->default_term ) ) {
+		delete_option( 'default_taxonomy_' . $taxonomy_object->name );
+	}
+
 	// Remove the taxonomy.
 	unset( $wp_taxonomies[ $taxonomy ] );
 
@@ -1824,6 +1829,15 @@ function wp_delete_term( $term, $taxonomy, $args = array() ) {
 		}
 	}
 
+	// Don't delete the default custom taxonomy term.
+	$taxonomy_object = get_taxonomy( $taxonomy );
+	if ( ! empty( $taxonomy_object->default_term ) ) {
+		$defaults['default'] = (int) get_option( 'default_taxonomy_' . $taxonomy );
+		if ( $defaults['default'] === $term ) {
+			return 0;
+		}
+	}
+
 	$args = wp_parse_args( $args, $defaults );
 
 	if ( isset( $args['default'] ) ) {
@@ -2516,9 +2530,11 @@ function wp_set_object_terms( $object_id, $terms, $taxonomy, $append = false ) {
 	$taxonomy_obj = get_taxonomy( $taxonomy );
 
 	// Default term for this taxonomy.
-	$default_term_id = get_option( 'default_taxonomy_' . $taxonomy );
-	if ( empty( $terms ) && ! empty( $taxonomy_obj->default_term ) && ! empty( $default_term_id ) ) {
-		$terms[] = (int) $default_term_id;
+	if ( empty( $terms ) && ! empty( $taxonomy_obj->default_term ) ) {
+		$default_term_id = get_option( 'default_taxonomy_' . $taxonomy );
+		if ( ! empty( $default_term_id ) ) {
+			$terms[] = (int) $default_term_id;
+		}
 	}
 
 	if ( ! $append ) {
diff --git tests/phpunit/tests/taxonomy.php tests/phpunit/tests/taxonomy.php
index 7a5a065be1..d2972729ca 100644
--- tests/phpunit/tests/taxonomy.php
+++ tests/phpunit/tests/taxonomy.php
@@ -999,9 +999,13 @@ class Tests_Taxonomy extends WP_UnitTestCase {
 			)
 		);
 
+		// Test default category.
 		$term = wp_get_post_terms( $post_id, $tax );
 		$this->assertSame( get_option( 'default_taxonomy_' . $tax ), $term[0]->term_id );
 
+		// Test default term deletion.
+		$this->assertSame( wp_delete_term( $term[0]->term_id, $tax ), 0 );
+
 		// Add custom post type.
 		register_post_type(
 			'post-custom-tax',
@@ -1017,5 +1021,8 @@ class Tests_Taxonomy extends WP_UnitTestCase {
 		);
 		$term    = wp_get_post_terms( $post_id, $tax );
 		$this->assertSame( get_option( 'default_taxonomy_' . $tax ), $term[0]->term_id );
+
+		unregister_taxonomy( $tax );
+		$this->assertSame( get_option( 'default_taxonomy_' . $tax ), false );
 	}
 }
