Post Syndicated from Prasad Nadig original https://aws.amazon.com/blogs/big-data/configure-domain-level-vpc-networking-in-amazon-sagemaker-unified-studio/
Enterprise operations teams that run domain-level VPC networking in Amazon SageMaker Unified Studio often support dozens of projects spanning data engineering, analytics, and machine learning (ML) teams. Each project requires private connectivity to internal databases, Amazon Simple Storage Service (Amazon S3) buckets, and AWS services. Without a domain-level Amazon Virtual Private Cloud (Amazon VPC) configuration, project owners coordinate with the networking team individually. This piecemeal approach leads to inconsistent subnet choices, missing VPC endpoints, connectivity failures that are hard to troubleshoot, and a network posture that is difficult to audit.
With domain-level VPC networking, you configure the network once, and all new projects get the right network immediately upon creation. In this post, you learn how to:
- Configure SageMaker Unified Studio domain-level VPC networking.
- Select subnets and security groups that provide multi-Availability Zone (multi-AZ) resilience.
- Update projects that have no VPC to inherit the domain VPC, and understand when a project must be recreated instead.
- Validate network connectivity from within a project.
In this post, you learn how to configure VPC networking for a SageMaker Unified Studio domain that uses AWS Identity and Access Management (IAM)-based authentication. You see how network components map to domain and project resources, and how to plan a configuration that balances security, connectivity, and operational simplicity.
Solution overview
Domain-level VPC networking provides a single network configuration that applies to all new projects in the domain. Projects automatically inherit the VPC settings, including subnets, security groups, and connectivity to AWS services through VPC endpoints. Existing projects are an exception and are handled separately (see Step 3).
The following diagram shows a single VPC with private subnets across two Availability Zones configured at the domain level, with data engineering, analytics, and ML projects all inheriting that configuration.
Figure 1: Domain-level VPC configuration in Amazon SageMaker Unified Studio. A single VPC with private subnets across two Availability Zones is configured at the domain level. All projects (data engineering, analytics, ML) inherit this configuration automatically
Key benefits of this approach:
- Configure once, apply across projects: New projects inherit the domain VPC without manual intervention.
- Consistent security posture: A single network boundary covers all data, analytics, and ML workloads.
- Simplified auditing: One VPC to audit rather than one per project. Turn on VPC Flow Logs and review AWS CloudTrail events for network-level auditing.
- Reduced operational overhead: Project teams start working immediately without submitting networking requests.
The following AWS services are used in this solution:
- Amazon SageMaker Unified Studio – The unified development environment for data, analytics, and AI.
- Amazon Virtual Private Cloud (Amazon VPC) – Provides network isolation with private subnets and VPC endpoints.
- IAM – Controls domain administrator permissions.
Prerequisites
Before configuring domain-level VPC networking, verify you have the following:
- Domain administrator permissions for Amazon SageMaker Unified Studio.
- An existing VPC with the following requirements:
- At least two private subnets in different Availability Zones.
- DNS hostnames and DNS support enabled.
- At least five available IP addresses per expected Amazon SageMaker Unified Studio project. This is a baseline minimum. Workloads using AWS Glue, Amazon EMR, or Amazon Redshift Serverless consume additional elastic network interfaces (ENIs) per worker or node. We recommend /24 or larger subnets for production domains and forward-looking capacity planning based on your expected users and compute types. For detailed guidance, see How to set up a network-isolated VPC for Amazon SageMaker Unified Studio.
- VPC endpoints configured for the AWS services your projects access (for example, Amazon S3, AWS Glue, Amazon SageMaker AI).
- Private DNS enabled on all interface VPC endpoints (you must enable this so that service DNS names resolve to private IPs). If you use centralized VPC endpoints through AWS Resource Access Manager (AWS RAM) or AWS Transit Gateway, configure Amazon Route 53 Resolver inbound endpoints instead.
- S3 gateway endpoint route table associations configured for all selected private subnets (without this, S3 access fails in subnets whose route table lacks the prefix-list route).
- A security group (optional), if not provided, SageMaker Unified Studio creates one automatically.
- The
SageMakerStudioAdminIAMConsolePolicymanaged policy (or equivalent permissions includingec2:Describe*,ec2:CreateSecurityGroup, anddatazone:*actions) attached to the domain administrator IAM role. SeeSageMakerStudioAdminIAMConsolePolicyin the AWS Managed Policy Reference for the full permission set.
Note: The VPC must be in the same AWS Region as the domain.
For detailed guidance on VPC networking configuration, see Configure VPC networking for IAM-based domains in the SageMaker Unified Studio Administrator Guide.
VPC endpoint requirements
Because your subnets are private (no internet gateway route), compute resources access AWS services through VPC endpoints. At a minimum, configure the following interface and gateway endpoints (add Amazon Athena, AWS Lake Formation, or Amazon Redshift endpoints if you use them in your projects):
| Endpoint | Type | Purpose |
| com.amazonaws.region.s3 | Gateway | S3 access for data storage |
| com.amazonaws.region.glue | Interface | AWS Glue job connectivity |
| com.amazonaws.region.sagemaker.api | Interface | SageMaker API calls |
| com.amazonaws.region.sagemaker.runtime | Interface | Model inference |
| com.amazonaws.region.logs | Interface | Amazon CloudWatch Logs |
| com.amazonaws.region.monitoring | Interface | Amazon CloudWatch metrics |
| com.amazonaws.region.sts | Interface | IAM role assumption |
| com.amazonaws.region.datazone | Interface | Amazon SageMaker Unified Studio service connectivity |
| com.amazonaws.region.ecr.api | Interface | ECR API calls (container image metadata) |
| com.amazonaws.region.ecr.dkr | Interface | ECR image layer pulls (Docker registry) |
| com.amazonaws.region.kms | Interface | AWS Key Management Service (AWS KMS) encryption/decryption operations |
Note: Interface endpoints incur an hourly charge per Availability Zone plus data processing fees. Gateway endpoints (such as S3) have no hourly charge. Factor endpoint count and AZ spread into your cost estimate.
For a comprehensive list of all mandatory and optional VPC endpoints for a fully network-isolated setup, see How to set up a network-isolated VPC for Amazon SageMaker Unified Studio. For current pricing details, see AWS PrivateLink pricing.
Note: Review your account’s service quotas for interface VPC endpoints per VPC (default 50) and ENIs per Region before scaling. Request increases through Service Quotas if needed.
Solution walkthrough
The following steps walk you through configuring the domain VPC and validating it, from signing in to the console through confirming private connectivity from a project.
Step 1: Sign in and navigate to networking settings
- Sign in to the AWS Management Console as your Amazon SageMaker Unified Studio domain administrator (the IAM role designated as the domain login role).
- Open the Amazon SageMaker console.
- Use the Region selector in the top navigation bar to select the Region where your domain exists.
- On the Amazon SageMaker Unified Studio landing page, choose Open to launch your IAM-based domain.
The following screenshot shows the Amazon SageMaker Unified Studio landing page, where you choose Open to launch the domain.
Figure 2: Amazon SageMaker Unified Studio landing page with the Open button to launch the IAM-based domain
- From the navigation pane, choose Domain management.
The following screenshot shows Domain management in the navigation pane.
Note: Access to the domain administration page is restricted to the IAM role specified as the domain login role during domain creation.
Step 2: Add VPC configuration
- In the navigation pane, choose Settings. In the Networking in this account section, choose Add VPC.
The following screenshot shows the Networking in this account section with the Add VPC button.
Figure 4: Domain management Settings page showing the Networking in this account section to add a VPC
- For VPC, select the VPC with connectivity to your compute, database, and storage resources. If no VPC exists, choose Create VPC to provision one using AWS CloudFormation.
- For Subnets, select a minimum of two private subnets in different Availability Zones.
- (Optional) For Security group, select a security group to control inbound and outbound traffic. If you don’t choose one, SageMaker Unified Studio creates one automatically.
- Choose Save.
- Verify the VPC configuration status shows Ready in the Networking in this account section.
The following screenshots show the Add VPC dialog and the resulting Ready status in the Networking in this account section.
Note: IAM-based domains support only one VPC configuration at a time. AWS IAM Identity Center-based domains can have a VPC per Region. For details, see Configure VPC networking for IAM-based domains in the SageMaker Unified Studio Administrator Guide.
New projects created in the domain now automatically use the saved VPC configuration. Existing projects are an exception. See Step 3 to update them.
Step 3: Update existing projects
Existing projects don’t automatically inherit the domain VPC configuration. How you apply the new settings depends on the project’s current state:
Projects with no VPC configured – Update in place to adopt the domain VPC. See the following steps.
Projects that already have a VPC – These can’t be switched to a different VPC configuration. To adopt the domain VPC:
- Create a new project (which inherits the domain VPC automatically).
- Recreate connections in the new project.
- Migrate assets from the old project.
- Back up any data you need, then delete the original project.
Because recreation can disrupt in-progress work and doesn’t migrate project data automatically, schedule this as a planned maintenance window.
To update a project that currently has no VPC configured:
- From the domain administration page, choose Projects in the navigation pane.
- Choose the project you want to update.
- On the project detail page, a banner appears: “Configurations have changed. Please update this project to access the latest configuration.”
- In the banner, choose Update.
- Confirm the update when prompted.
Repeat this process for each existing project that should use the domain VPC. The following screenshot shows the project detail page with the configuration update banner.
Step 4: Validate connectivity
After configuring the domain VPC and updating your projects, verify connectivity. Compute resources should have private connectivity to AWS services through the VPC, without any additional project-level network configuration.
Create a notebook in one of your projects as shown in the following figure and run the following code:
Requirements: Python 3.8+, Boto3 1.26 or later. Run in a notebook within your SageMaker Unified Studio project.
Expected output when VPC is correctly configured:
Figure 9: Successful validation output showing all services accessible through private VPC endpoints
If any service shows a failure, one common cause is security groups preventing traffic on port 443 to the VPC endpoint. Other causes include missing VPC endpoints, incorrect route table entries, or DNS resolution issues. For more information, see Configure VPC networking for IAM-based domains in the SageMaker Unified Studio Administrator Guide.
Note: An AccessDenied error indicates the request reached the service. Connectivity is working, but IAM permissions need adjustment (for example, the S3 test requires s3:ListAllMyBuckets, which some project roles lack). A timeout or connection error points to a networking problem (missing endpoint, route, or security group rule). The following screenshot shows the validation output when VPC endpoints are missing, where the affected services report timeout errors.
Figure 10: Validation output when VPC endpoints are not configured. Timeout errors indicate missing endpoints
The security group applied at the domain level controls network access for all projects. To review or tighten the rules:
- Navigate to the Amazon VPC console.
- Choose Security groups and choose the security group shown in your domain’s Networking settings.
- Review the Inbound rules and Outbound rules tabs.
By default, the auto-created security group allows all outbound traffic on port 443 (HTTPS) to reach AWS services through VPC endpoints. Consider restricting outbound rules to only the specific VPC endpoint security groups for least-privilege access. Additionally, make sure your VPC endpoint security groups allow inbound TCP 443 from the domain security group or subnet CIDRs. For distributed compute services (AWS Glue, Amazon EMR), add a self-referencing inbound rule to allow worker-to-worker communication.
Updating VPC configuration
After the initial setup, you can modify the VPC configuration to change the VPC, subnets, or security group:
- From the domain administration page, choose Settings in the navigation pane.
- In the Networking in this account section, under the Actions column, choose Update.
- Update the VPC, subnets, or security group as needed.
- Choose Update.
The following screenshot shows the Update VPC dialog, where you modify the VPC, subnets, or security group.
Figure 11: Update VPC dialog showing the option to modify VPC, subnets, or security group for the domain
Important: Updating the VPC does not affect already provisioned resources. Newly created resources in projects use the updated VPC. Existing projects that already have a VPC keep their original settings and must be recreated to adopt the change. Projects with no VPC can be updated in place (see Step 3).
Clean up
To remove the VPC configuration from your domain:
- From the domain administration page, choose Settings in the navigation pane.
- In the Networking in this account section, choose the Actions menu (⋮) and choose Remove.
The following screenshot shows the Actions menu with the Remove option.
If you created a dedicated VPC for this walkthrough and no longer need it:
- Delete the VPC and associated resources (subnets, VPC endpoints, security groups) from the Amazon VPC console. Before deleting, remove the domain VPC configuration and make sure all project resources are terminated. Active projects create ENIs that block VPC and subnet deletion.
- If you used an AWS CloudFormation template to create the VPC, delete the stack to remove all resources cleanly. Open the AWS CloudFormation console and delete the stack.
Note: Removing the domain VPC configuration does not retroactively change projects that already have VPC applied. Those projects retain their existing network configuration. New projects created after removal do not have a VPC configured.
Conclusion
In this post, we showed how to configure domain-level VPC networking in Amazon SageMaker Unified Studio. A single domain-level VPC eliminates per-project networking overhead, enforces a consistent security posture, and simplifies compliance auditing.
Key takeaways:
- Domain-level VPC is a one-time configuration that automatically applies to all new projects.
- Projects with no VPC can be updated in place. Projects that already have a VPC must be recreated to adopt a changed configuration.
- Private subnets with VPC endpoints provide secure, private connectivity to AWS services without traversing the public internet.
As next steps, consider:
- Reviewing your auto-created security group rules and tightening them for least-privilege access.
- Adding VPC endpoints for additional AWS services as your projects’ needs evolve.
- Monitoring subnet IP address utilization to plan capacity as you add more projects. Use the AvailableIpAddressCount Amazon CloudWatch metric for your subnets to track utilization and set alarms.
For more information, see Configure VPC networking for IAM-based domains in the Amazon SageMaker Unified Studio Administrator Guide.




























