# Clear notifications with a keyboard shortcut!!!

**URL:** <https://community.folivora.ai/t/clear-notifications-with-a-keyboard-shortcut/30335>\
**Category:** Setup/Preset Sharing\
**Tags:** keyboard\
**Created:** [February 13, 2023, 4:32pm UTC](https://community.folivora.ai/t/clear-notifications-with-a-keyboard-shortcut/30335 "2023-02-13T16:32:51Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![abcd](https://community.folivora.ai/letter_avatar_proxy/v4/letter/a/c57346/32.png) [@abcd](https://community.folivora.ai/u/abcd)\
**Post date:** [February 13, 2023, 4:32pm UTC](https://community.folivora.ai/t/clear-notifications-with-a-keyboard-shortcut/30335/1 "2023-02-13T16:32:51Z")

</div>

# Close notification with keyboard shortcut! (no need to open notifications center)

1. Find the position of the little "x" button on the notification, for me that's 1324,20 on a MacBook Air.
2. Install [cliclick](https://github.com/BlueM/cliclick#installation) (`brew install cliclick`)
3. Use this as a shell script:

```shell
POS=$(/opt/homebrew/bin/cliclick p)
/opt/homebrew/bin/cliclick c:1324,20
/opt/homebrew/bin/cliclick m:$POS

```

 ![image](https://community.folivora.ai/uploads/default/original/3X/6/b/6b72193beb75612e52660f305091e49872736888.jpeg)

---

<div class="post-metadata">

**Author:** ![Andreas\_Hegenberg](https://community.folivora.ai/user_avatar/community.folivora.ai/andreas_hegenberg/32/39221_2.png) [@Andreas\_Hegenberg](https://community.folivora.ai/u/Andreas_Hegenberg)\
**Post date:** [February 13, 2023, 4:34pm UTC](https://community.folivora.ai/t/clear-notifications-with-a-keyboard-shortcut/30335/2 "2023-02-13T16:34:32Z")

</div>

Or you can use the "Close All Notification Alerts" predefined action that is included in BTT 😉

---

<div class="post-metadata">

**Author:** ![abcd](https://community.folivora.ai/letter_avatar_proxy/v4/letter/a/c57346/32.png) [@abcd](https://community.folivora.ai/u/abcd)\
**Post date:** [February 13, 2023, 7:11pm UTC](https://community.folivora.ai/t/clear-notifications-with-a-keyboard-shortcut/30335/3 "2023-02-13T19:11:54Z")

</div>

I spent 2 hours figuring out how to do this ='( Thanks though lol

---

<div class="post-metadata">

**Author:** ![Andreas\_Hegenberg](https://community.folivora.ai/user_avatar/community.folivora.ai/andreas_hegenberg/32/39221_2.png) [@Andreas\_Hegenberg](https://community.folivora.ai/u/Andreas_Hegenberg)\
**Post date:** [February 13, 2023, 7:19pm UTC](https://community.folivora.ai/t/clear-notifications-with-a-keyboard-shortcut/30335/4 "2023-02-13T19:19:07Z")

</div>

😀 also note you can use BTT's "move mouse to position" and leftclick actions to click anywhere on your screen. So you would not need click click eben when doing it like this

---

<div class="post-metadata">

**Author:** ![stevemac](https://community.folivora.ai/letter_avatar_proxy/v4/letter/s/94ad74/32.png) [@stevemac](https://community.folivora.ai/u/stevemac)\
**Post date:** [July 10, 2023, 8:27am UTC](https://community.folivora.ai/t/clear-notifications-with-a-keyboard-shortcut/30335/5 "2023-07-10T08:27:47Z")

</div>

Thanks @Andreas_Hegenberg one of the more annoying things about MacOS, is the notification alerts about disconnecting external drives. You've helped me to fix this nicely, but open to any further suggestions.

 ![CleanShot 2023-07-10 at 18.23.41@2x](https://community.folivora.ai/uploads/default/original/3X/b/e/be3309889da735963e2c3de7586e1a55e66763cd.png)
