A Kubernetes namespace gives a team, application, or environment its own naming scope inside one cluster. It is useful when workloads need separate object names, policies, quotas, and access boundaries without creating another cluster.
kubectl create namespace sends a Namespace object to the API server and returns after the object is accepted. The namespace name must be unique across the cluster, and namespaced objects can then be created with --namespace or a context that already selects that namespace.
A namespace does not isolate compute by itself. Pair it with RBAC, ResourceQuota, LimitRange, labels, and network policy when the new area needs real tenant, team, or environment controls.
$ kubectl create namespace team-a namespace/team-a created
Use a DNS-label style name such as team-a or staging. Namespace names are cluster-wide, so choose a name that will not conflict with another team or environment.
$ kubectl get namespace team-a NAME STATUS AGE team-a Active 0s
The Active phase means the API server accepted the namespace and it is available for namespaced resources.
$ kubectl create configmap namespace-smoke --from-literal=owner=team-a --namespace team-a configmap/namespace-smoke created
The --namespace flag keeps the test object in the new namespace without changing the current kubectl context.
$ kubectl get configmap namespace-smoke --namespace team-a NAME DATA AGE namespace-smoke 1 0s
$ kubectl delete configmap namespace-smoke --namespace team-a configmap "namespace-smoke" deleted from team-a namespace
The namespace remains in place for application objects, RBAC bindings, quotas, and policies after the smoke-test object is removed.