Collaboration in Zed
Real-time multiplayer coding and team collaboration
Zed's Collaboration Philosophy
Collaboration is at the heart of Zed's design. Unlike traditional editors that treat collaboration as an add-on feature, Zed was built from the ground up for real-time multiplayer editing:
- Native Integration: Collaboration is a core feature, not a plugin
- Low Latency: Designed for real-time interaction with minimal delay
- End-to-End Encryption: Secure communication between collaborators
- Persistence: Projects and sessions are maintained between connections
Setting Up Your Account
Before collaborating in Zed, you need to set up a Zed account:
-
Create an Account
If you haven't already done so, create a Zed account by clicking on your username in the bottom left corner of the editor and selecting "Sign Up" or "Sign In."
-
Set Your Display Name
Choose a display name that will be visible to your collaborators. You can set this when creating your account or update it later in your profile settings.
-
Add Collaborators
Connect with collaborators by adding them as contacts. Press ⌘ShiftP, type "Contacts," and select "Add Contact" to search for and add team members by their username or email.
Your Zed account credentials are used only for collaboration features and synchronized settings. You can still use Zed offline without an account for solo development.
Creating Collaborative Sessions
Starting a New Session
There are several ways to start collaborating:
-
Host a Project
Open the project you want to share, then press ⌘ShiftP and type "Share Project" to start hosting your current project.
-
Invite Collaborators
After hosting, you'll get a shareable link or you can directly invite contacts from your list. Select the collaborators you want to invite and send the invitation.
-
Set Permissions
Choose whether collaborators can edit or only view your project. You can also set permissions on a per-user basis for more fine-grained control.
For quick collaboration sessions, you can use the "Copy Invite Link" option to generate a URL that can be shared through any communication channel.
Joining Collaborative Sessions
Accepting Invitations
Join a collaborative session through invitations:
- Via Notifications: When invited, you'll receive a notification in Zed that you can click to join
- Via Links: Click a shared link to open it directly in Zed
- Via Contacts: View your online contacts and join their active sessions
The Collaboration Panel
Once connected, the Collaboration Panel shows active participants:
- View all connected collaborators
- See everyone's cursor position and selections
- Follow a specific collaborator's view
Working Together in Real-Time
Multiplayer Editing
With Zed's multiplayer editing, everyone can simultaneously edit the same files:
- Cursor Awareness: See everyone's cursor position with their name label
- Selection Visibility: See what others are selecting in real-time
- Conflict Resolution: Zed automatically handles conflicting edits
When multiple people edit the same area, Zed uses operational transforms to preserve everyone's intent without locking or overwriting changes.
Following Collaborators
You can choose to follow another collaborator's view:
-
Enable Following
Click on a collaborator's name in the Collaboration Panel and select "Follow" to automatically track their cursor position and file navigation.
-
Stop Following
Click anywhere in the editor or press Esc to stop following and resume independent navigation.
Communication During Collaboration
Chat
Zed includes a built-in text chat for communicating with collaborators:
- Press ⌘ShiftC to open the chat panel
- Send messages to all collaborators
- Share code snippets or links
Voice Chat
For direct communication, Zed also offers voice chat:
- Click the microphone icon in the Collaboration Panel to toggle voice chat
- Adjust voice settings in the preferences
- Mute yourself or specific participants as needed
Voice and text communication in Zed are also end-to-end encrypted, ensuring that your team discussions remain private.
Collaboration Workflows
Pair Programming
Zed's collaboration features are perfect for pair programming:
- Driver/Navigator: Take turns typing while the other navigates
- Ping-Pong: Write a failing test, then have your partner make it pass
- Side-by-Side: Work on different parts of the same file simultaneously
Code Reviews
Conduct interactive code reviews in real-time:
- Walk through changes together with voice chat
- Make suggested edits immediately
- Discuss implementation details while examining code
Team Collaboration
For larger teams, Zed supports:
- Multiple collaborators working on different files in the same project
- Shared terminal sessions for running tests or builds
- Group discussion through voice and text
Create channels for different projects or teams to organize your collaborative workspaces and keep long-running collaboration sessions separate.
Managing Permissions and Security
Permission Levels
As a host, you can set different permission levels for collaborators:
- Edit: Full ability to edit all files in the project
- View Only: Can see files and follow others, but cannot make changes
- Terminal Access: Control whether collaborators can use the terminal
Security Considerations
Keep your collaborative sessions secure:
- Use single-use invitation links when collaborating with external participants
- Set expiration times on shared sessions
- Remove collaborators when they no longer need access
- Be mindful of sensitive information in shared terminals
Ending Collaboration Sessions
When you're finished collaborating:
-
Save All Changes
Press ⌘S to save current file or ⌘⌥S to save all files.
-
End the Session
As the host, press ⌘ShiftP, type "End Collaboration," and select it to terminate the session for all participants.
-
Leave a Session
As a participant, press ⌘ShiftP, type "Leave Collaboration," and select it to disconnect from the session.
When a session ends, collaborators can save their own copies of the files they were working on if they need to keep the changes.
What's Next?
Now that you've learned how to collaborate in Zed, you're ready to explore the integrated terminal for running commands and managing your development environment without leaving the editor.