Changing default font size in Safari using JavaScript I like to decrease the zoom and the font size of Safari for a better overview, I know I can set a default zoom value, but can I set a default font size?

I'm using JavaScript at the moment but I have to do that to each tab.

javascript:var p=document.getElementsByTagName('*');for(i=0;i&lt;p.length;i++){if(p[i].style.fontSize){var s=parseInt(p[i].style.fontSize.replace("px",""));}else{var s=12;}s+=2;p[i].style.fontSize=s+"px"}
Your question doesn't provide a lot of detail, and it's also a little ambiguous (hence the comments you're getting). 

Here is an answer assuming you're wanting to do this for your own personal web browsing, rather than as a web developer. This answer also assumes you're trying to only reduce the font size rather than the whole page.

Since there's no way to do this through Safari's preferences, you have two options open to you:


Using a custom style sheet
Installing an extension


Style sheet

If you know how to create your own style sheet, then follow these steps:


Create a style sheet to set your font properties
Go to the Safari > Preferences menu
Select the Advanced tab
In the Style Sheet drop-down menu, select Other...
Navigate to your style sheet and select it
Exit the Safari preferences.


Extension

There are probably many extensions that will achieve what you want. Here are the steps for one that I'm aware of:


Go to: https://safari-extensions.apple.com/details/?id=com.sobolev.stylish-5555L95H45
Install the Stylish extension
Restart Safari
Take note that to the left of the address bar you should now see the Stylish S button
Go to: https://userstyles.org/styles/68263/global-font-size
Click on the Install with Stylish button
You've now installed this style


Now, if you need to customise this style, do the following:


click on the Stylish S button I referred to at Step 4 above.
Click on Manage
Under the Global Font Size option click on Edit
This displays the CSS code for this style. Edit it as you need.
Save your changes


Hope this helps.

If I've misunderstood your question, please clarify it.