Celeb Glow
news | March 20, 2026

Close a specific Chrome tab using /bash

So I have multiple in instances of Chrome opened to different sites with different profiles in chrome

#! /bin/bash
google-chrome --profile-directory=Default
google-chrome --profile-directory=Profile1
google-chrome --profile-directory=Profile2
google-chrome --profile-directory=Profile3 

is there a way i can close for ex only Profile 2 runing with out affecting the rest ? using a similar /bash

1 Answer

closing chrome from terminal might not save profile details properly. You can install wmctrl to close chrome tab with title as below: wmctrl -c window-title

4

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy