You can use your hosts file to redirect all traffic in a local black hole (namely 0.0.0.0)

sudo vi /etc/hosts

Add the following lines (plus hosts you find out by yourself) to /etc/hosts and save it:

0.0.0.0 google-analytics.com
0.0.0.0 www.google-analytics.com
0.0.0.0 googletagmanager.com
0.0.0.0 www.googletagmanager.com
0.0.0.0 hn.inspectlet.com
0.0.0.0 api.segment.io

if you check the network tab in your browser, you will see something like this:

![block](data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABB0AAAAXCAMAAABwD8fZAAABdGlDQ1BpY2MAACiRY2BgKkksKMhhYWBgyM0rKQpyd1KIiIxSYL/DwM3AwyDEYMUgnphcXOAYEODDgBN8u8bACKIv64LMSvP8edOmtXz+FjavmXJWJTq49YEBd0pqcTIDAyMHkJ2cUpycC2TnANk6yQVFJUD2DCBbt7ykAMQ+AWSLFAEdCGTfAbHTIewPIHYSmM3EAlYTEuQMZEsA2QJJELYGiJ0OYVuA2MkZiSlAtgfILogbwIDTw0XB3MBS15GAu0kGuTmlMDtAocWTmhcaDHIHEMsweDC4MCgwmDMYMFgy6DI4lqRWlIAUOucXVBZlpmeUKDgCQzZVwTk/t6C0JLVIR8EzL1lPR8HIwNAApA4UZxCjPweBTWcUO48Qy1/IwGCpzMDA3IMQS5rGwLB9DwODxCmEmMo8BgZ+awaGbecKEosS4Q5n/MZCiF+cZmwEYfM4MTCw3vv//7MaAwP7JAaGvxP///+96P//v4uB9gPj7EAOACR3aeD+qnTyAAAAIGNIUk0AAHomAACAhAAA+gAAAIDoAAB1MAAA6mAAADqYAAAXcJy6UTwAAALxUExURZzkr5Lip93d3crJyoHIlEidtZ1yVp3msBQUFBYWFvL3/+/0/dPY3+/1/XKm4Mx6fPH2/RMTExcXF/D1/fL3/u/0/PD2/fL2/re7wr/Cye/0+/D0/JuepP///+7h6e3X4O/y++/w+e3T3O7i6u7Z4u7q8+/v+O/t9u3U3e3P1+/z/PH2/qWpr+y/x+MVGe/u9+ZRVuIAAeQsMO7c5O3R2eU/ROugp+MKEO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