External CSS and Javascript

dayzia122
Shopify Partner
6 0 0

l'm trying to add external CSS and Javascript to my website but I'm not sure how to. I'm not the most advanced with code so I've tried doing research but I'm still stuck. I have a Shopify theme, has anyone had any experience with this?

Replies 4 (4)
paulryazanov
Shopify Partner
104 10 22

Hi! For adding external css just add this tag <link rel="stylesheet" href="styles.css"> (https://www.w3schools.com/tags/att_link_rel.asp) before </head> tag in your theme.liquid file 
For adding scripts do same as styles tag but use <script src="link"></script>

CEO of MageCloud.agency
dayzia122
Shopify Partner
6 0 0

So for the scripts would I write it as <script src="link"</script>?

 

or is "link" supposed to be something like the website link?

dayzia122
Shopify Partner
6 0 0

dayzia122_0-1648741128625.png

 

dayzia122
Shopify Partner
6 0 0

So for the scripts would I write it as <script src="link"</script>?

 

or is "link" supposed to be something like the website link?