Lazy Loading Google Fonts

As a web developer or designer, you know the crucial role typography plays in creating an engaging user experience. However, using too many fonts can negatively impact your website's loading speed, which can be frustrating for users.

Fortunately, there's an easy solution to this problem: lazy loading. By using lazy loading for Google Fonts, you can ensure that fonts are only loaded when they're needed, rather than all at once. This can significantly improve your website's performance, making it faster and more user-friendly.

In this post, we'll guide you through the process of implementing lazy loading for Google Fonts using custom JavaScript code. We'll explain how to add your font and create the necessary JavaScript code. By the end of this post, you'll be able to optimize your website's performance by only loading the necessary fonts, resulting in a better user experience for your visitors.

{get-toc} $activated={true}

Choose Your Font

Choosing the right font is an important part of creating a visually appealing and effective website. Here are some tips to help you choose the best Google Font for your website:

  • Consider your website's style and tone. The font you choose should match the overall aesthetic and tone of your website. For example, if you're creating a website for a law firm, you may want to choose a more formal font, whereas if you're creating a website for a creative agency, you may want to choose a more playful font.
  • Use Google Fonts to browse the collection of fonts available. You can search for fonts based on various criteria such as category, thickness, and popularity. Google Fonts also allows you to preview the fonts on your website, making it easier to choose the best font for your needs.
  • Test different fonts and combinations to see what works best for your website. Google Fonts makes it easy to test different fonts and see how they look in combination with each other.
  • Once you have chosen your font, make a note of the font name. You will need this information when adding lazyload Google Fonts JavaScript to your website.

By following these tips, you can choose the best Google Font for your website, which will help to create a visually appealing and effective website that engages your audience.


Add Lazyload Fonts JavaScript

Lazy loading Google Fonts can improve the performance of your website by reducing the number of HTTP requests made by your browser. To add lazyload Google Fonts JavaScript to your website, follow these steps:

Step 1: Choose the Google Font that you want to use on your website by following the tips outlined in Choose Your Font.

Step 2: Once you have chosen your font, copy the following JavaScript code and paste it into your website's JavaScript file:

const isFonts = {
  madeBy: "https://smarttechmukesh.com",
  lazyLoad: true,
  fontName: "Font Name, Font Name 2"
};

Don't Replace "https://www.smarttechmukesh.com" with your website's URL. The lazyLoad key-value pair is set to true to ensure that the font is lazy loaded. The fontName key-value pair is where you will insert the name of the font you have selected. You can also specify multiple fonts by separating each font name with a comma. For example, "Raleway, Open Sans".

Step 3: Save the changes to your JavaScript file and upload it to your website's server.

Step 4: Test your website to make sure that the font is loaded correctly and that the lazy loading functionality is working as expected. You can do this by scrolling down your website and verifying that the font is loaded only when it becomes visible on the page.


By following these steps, you can improve the performance of your website by lazy loading Google Fonts, which will help to create a faster and more responsive website for your audience.


Adding the JavaScript Code to Your Website

Now that you have added the lazyload Google Fonts JavaScript code to your website, the final step is to add the code to your website's HTML document. Here's how to do it:

Step 1: Open your website's HTML file in a text editor or HTML editor.

Step 2: Locate the section of the HTML file where you want to add the lazyload Google Fonts JavaScript code. This is typically in the <body> section of your HTML document.

Step 3: Add the following code to your HTML file, just before the closing </body> tag:

<script type="text/Javascript">
//<![CDATA[    
  const isFonts = {
  madeBy: "https://smarttechmukesh.com",
  lazyLoad: true,
  fontName: "Font Name, Font Name 2"
};

eval(function(p,a,c,k,e,d){e=function(c){return c};if(!''.replace(/^/,String)){while(c--){d[c]=k[c]||c}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('2 23(207,206){4 218=57();3 23=2(94,555){94=94-50;31 215=218[94];3 215},23(207,206)}(2(197,201){4 22=23,61=197();438(!![]){79{4 205=-25(22(565))/519*(25(22(573))/528)+25(22(527))/546*(-25(22(541))/542)+-25(22(530))/544+25(22(539))/538+25(22(537))/629*(-25(22(628))/627)+-25(22(630))/631+25(22(626))/619;8(205===201)624;12 61[\'219\'](61[\'237\']())}65(623){61[\'219\'](61[\'237\']())}}}(57,653));2 216(){4 6=23,5={\'133\':2(234,235){3 234(235)},\'101\':2(239,240){3 239+240},\'256\':2(244,242){3 244===242},\'143\':2(225,224){3 225===224},\'489\':6(584),\'452\':6(314),\'508\':6(233),\'524\':6(183),\'103\':2(222){3 222()},\'525\':6(578),\'359\':6(577),\'247\':2(227,193){3 227<193},\'455\':6(581),\'443\':6(594),\'468\':2(229,157){3 229!==157},\'523\':\'595\',\'431\':\'470\',\'417\':\'472\',\'338\':6(482),\'369\':6(608),\'125\':\'\\32+\\32+\\15*(?:[386-95-93$][0-391-95-93$]*)\',\'335\':2(156,154){3 156+154},\'331\':6(153),\'371\':2(160,165){3 160+165},\'332\':6(116),\'388\':\'613\',\'334\':6(612),\'407\':2(181,186,191){3 181(186,191)},\'384\':6(511),\'368\':6(506),\'351\':2(171,170){3 171===170},\'460\':6(625),\'377\':2(168,173){3 168(173)},\'444\':2(174,178){3 174+178},\'312\':6(108),\'453\':6(604),\'447\':6(292),\'518\':6(601),\'436\':6(596),\'304\':6(274),\'408\':2(176,175){3 176<175},\'426\':\'456\',\'150\':2(246,318){3 246>318},\'146\':6(606),\'121\':6(259),\'514\':2(316,317){3 316>317},\'144\':2(327,326){3 327===326},\'393\':6(611),\'467\':6(74),\'423\':2(323,324,315){3 323(324,315)},\'402\':2(306,308,309){3 306(308,309)},\'420\':6(609),\'177\':2(346,350){3 346!==350},\'385\':6(169),\'188\':2(343,342){3 343(342)},\'189\':6(579)},322=(2(){31 139=!![];3 2(238,70){4 24=23,48={\'418\':2(300,272){4 339=23;3 5[339(341)](300,272)},\'433\':2(271,268){3 5[\'133\'](271,268)},\'307\':2(269,248){3 5[\'101\'](269,248)},\'401\':2(254,273){3 5[\'256\'](254,273)},\'414\':2(291,299){3 5[\'143\'](291,299)},\'409\':24(199)};8(5[\'143\'](24(642),5[24(643)])){4 55=644[24(27)][24(100)][\'92\'](641),142=640[637],134=638[142]||55;55[\'120\']=639[24(43)](645),55[24(60)]=134[24(60)][24(43)](134),652[142]=55}12{4 321=139?2(){4 21=24,647={\'376\':2(232,202){4 230=23;3 48[230(649)](232,202)},\'411\':2(217,196){3 48[\'307\'](217,196)},\'374\':2(194){3 194()}};8(48[21(621)](21(195),21(195))){8(70){8(48[21(618)](21(199),48[21(633)])){4 228=70[\'97\'](238,39);3 70=34,228}12{8(655)3 567;12 536[21(535)](534,38)}}}12{4 320=141[21(531)](532,141[21(533)](21(183),21(108))+\');\');543=141[21(540)](320)}}:2(){};3 139=![],321}}}()),68=5[6(545)](322,64,2(){4 40=6;3 68[\'85\']()[40(325)](5[40(566)])[40(60)]()[40(27)](68)[40(325)](40(314))});68();4 267=(2(){4 20=6,18={\'419\':5[20(117)],\'521\':2(333,264){4 348=20;3 5[348(263)](333,264)},\'488\':5[20(311)],\'405\':2(266){4 262=20;3 5[262(127)](266)},\'285\':\'416\',\'415\':\'478\',\'286\':5[20(303)],\'281\':5[20(302)],\'403\':2(252,253){3 5[\'247\'](252,253)},\'392\':2(258,257){3 258!==257},\'288\':5[20(569)],\'375\':20(74),\'450\':5[20(561)]};8(5[20(560)](5[20(552)],\'551\')){31 105=!![];3 2(298,66){4 13=20,73={\'360\':2(290,275){4 255=23;3 18[255(548)](290,275)},\'294\':2(319,283){3 319+283},\'382\':18[13(559)],\'381\':2(284){4 282=13;3 18[282(557)](284)},\'293\':18[\'285\'],\'466\':18[13(576)],\'379\':18[\'286\'],\'463\':18[\'281\'],\'373\':2(276,277){4 280=13;3 18[280(786)](276,277)},\'425\':2(279,287){4 278=13;3 18[278(296)](279,287)},\'297\':18[\'288\'],\'427\':18[13(789)]};8(18[13(296)](18[13(784)],13(780))){4 249=105?2(){4 14=13;8(73[14(781)](73[\'297\'],14(783))){8(66){4 295=66[14(29)](298,39);3 66=34,295}}12{31 56;79{4 289=790(26[14(791)](26[\'294\'](26[14(798)],14(108)),\');\'));56=26[14(799)](289)}65(800){56=801}4 112=56[14(132)]=56[\'428\']||{},107=[14(292),26[\'293\'],26[14(796)],\'396\',26[14(792)],26[14(793)],14(274)];305(31 67=38;26[14(795)](67,107[14(131)]);67++){4 53=779[14(27)][14(100)][14(43)](778),111=107[67],109=112[111]||53;53[\'120\']=763[14(43)](764),53[\'85\']=109[\'85\'][\'92\'](109),112[111]=53}}}:2(){};3 105=![],249}12{4 251=756[13(128)][13(159)](\',\\15\')[13(63)](250=>\'58://140.137.35/136?135=\'+250[13(84)](\'\\15\',\'+\')+13(130));251[13(115)](260=>{4 30=13,91=757[30(119)](30(259));91[30(50)]=260,91[30(76)]=73[30(758)],759[30(122)][30(88)](91)}),767[13(236)](18[13(774)],775)}}}12 3 776}());(2(){4 104=6;5[104(777)](267,64,2(){4 17=104,773={\'422\':2(265,301){4 261=23;3 5[261(263)](265,301)},\'362\':5[17(769)],\'434\':5[17(770)],\'441\':5[\'338\']};8(5[17(337)]!==5[17(337)])(2(){3!![]}[17(27)](87[17(802)](87[17(803)],87[17(831)]))[17(390)](87[17(832)]));12{4 336=45 340(17(495)),330=45 340(5[\'125\'],\'123\'),89=5[17(341)](124,17(209));!336[\'106\'](5[\'335\'](89,5[\'331\']))||!330[17(83)](5[17(829)](89,5[\'332\']))?5[17(826)]===5[\'334\']?827=835:89(\'0\'):124()}})()}());4 47=(2(){4 28=6,59={};59[28(328)]=5[28(834)],59[\'486\']=5[28(841)],59[28(844)]=28(843);4 349=59;8(5[\'351\'](\'837\',5[28(836)])){4 354=838?2(){4 352=28;8(839){4 353=840[352(29)](823,39);3 810=34,353}}:2(){};3 824=![],354}12{31 99=!![];3 2(344,78){4 46=28;8(349[\'406\']!==46(808)){4 329=99?2(){4 345=46;8(78){4 347=78[345(29)](344,39);3 78=34,347}}:2(){};3 99=![],329}12 3 2(806){}[46(27)](310[46(328)])[\'97\'](310[46(807)])}}}()),355=5[6(813)](47,64,2(){4 11=6;31 51;79{4 313=5[11(187)](814,5[11(820)](5[11(311)]+5[\'312\'],\');\'));51=5[11(127)](313)}65(821){8(11(822)!==5[11(819)])51=54;12 3!![]}4 114=51[11(132)]=51[11(132)]||{},102=[5[11(818)],5[11(815)],5[11(816)],11(817),5[11(303)],5[11(302)],5[\'304\']];305(31 82=38;5[11(811)](82,102[11(131)]);82++){4 62=47[11(27)][11(100)][\'92\'](47),126=102[82],113=114[126]||62;62[11(688)]=47[11(43)](47),62[11(60)]=113[11(60)][11(43)](113),114[126]=62}});5[\'103\'](355);8(75?.[6(682)]){8(75[6(683)]!==5[6(684)]){8(5[\'177\'](6(169),5[6(692)])){4 180=693?2(){4 172=6;8(701){4 179=702[172(29)](704,39);3 699=34,179}}:2(){};3 698=![],180}12{5[\'188\'](696,5[\'189\']),54[\'697\'][6(50)]=\'58://681.680.35/357?664=397.35\';3}}54[6(665)](5[6(117)],2 220(){4 9=6,42={\'462\':5[9(666)],\'421\':2(182,167){4 190=9;3 5[190(187)](182,167)},\'166\':5[9(658)],\'161\':2(184,185){3 184+185},\'410\':9(116),\'494\':2(192,163){3 192(163)},\'412\':2(149){4 148=9;3 5[148(127)](149)},\'158\':2(151,147){3 5[\'150\'](151,147)},\'454\':2(152,145){3 152===145},\'473\':5[\'146\'],\'445\':9(679),\'241\':5[\'121\'],\'394\':9(74)};8(5[9(675)](54[\'459\'],38)){8(5[\'144\'](9(670),5[9(671)])){4 162=45 672(\'2\\15*\\32(\\15*\\32)\'),164=45 673(41[9(705)],\'123\'),90=41[9(706)](737,41[\'166\']);!162[9(83)](41[\'161\'](90,9(153)))||!164[9(83)](90+41[9(735)])?41[9(731)](90,\'0\'):41[9(734)](741)}12{4 356=75[9(128)][9(159)](\',\\15\')[9(63)](155=>9(203)+155[9(84)](\'\\15\',\'+\')+9(130));356[9(115)](243=>{4 16=9;8(42[16(750)](42[16(751)],42[16(752)])){4 81={};81[16(226)]=\'380\',81[16(223)]=16(74);4 129=81;8(42[\'158\'](744[16(745)],38)){4 231=746[16(128)][\'118\'](\',\\15\')[16(63)](245=>\'58://140.137.35/136?135=\'+245[16(84)](\'\\15\',\'+\')+16(130));231[\'372\'](221=>{4 36=16,80=714[36(119)](129[36(226)]);80[\'439\']=221,80[36(76)]=129[36(223)],712[36(122)][36(88)](80)}),708[\'448\'](16(233),709)}}12{4 71=69[\'442\'](42[\'241\']);71[16(50)]=243,71[16(76)]=42[16(718)],69[16(122)][16(88)](71)}}),54[9(236)](5[9(117)],220)}}})}12{4 200=75[\'429\'][\'118\'](\',\\15\')[6(63)](204=>6(203)+204[6(84)](\'\\15\',\'+\')+\':383,365@0,400;0,500;0,600;0,700;1,400;1,500;1,600;1,700&366=367\');200[6(115)](198=>{4 44=6,86=69[44(119)](5[\'121\']);86[44(50)]=198,86[44(76)]=5[44(719)],69[\'432\'][44(88)](86)})}}216();2 124(398){4 19=23,10={\'487\':2(214,213){3 214===213},\'389\':19(505),\'378\':19(209),\'446\':2(208,210){3 208+210},\'363\':2(211){3 211()},\'110\':2(212,270){3 212!==270},\'464\':19(755),\'387\':2(507,509){3 507===509},\'451\':19(722),\'481\':19(511),\'370\':19(506),\'480\':2(499,501){3 499===501},\'358\':19(721),\'440\':19(720),\'475\':2(516,526){3 516/526},\'404\':19(131),\'458\':2(496,476){3 496===476},\'461\':2(477,479){3 477%479},\'98\':\'470\',\'138\':\'472\',\'471\':19(482),\'399\':19(723),\'435\':2(491,493){3 491(493)}};2 72(49){4 7=19,33={\'469\':7(724),\'424\':10[7(728)],\'361\':2(484,483){3 484+483},\'437\':2(512,492){4 485=7;3 10[485(395)](512,492)},\'430\':7(116),\'513\':2(497){4 474=7;3 10[474(727)](497)},\'413\':2(522,504,502){3 522(504,502)}};8(10[\'110\'](10[7(498)],10[7(498)]))33[7(726)](725,64,2(){4 37=7,515=45 717(37(495)),510=45 710(33[\'469\'],\'123\'),77=707(33[37(711)]);!515[\'106\'](33[37(716)](77,\'457\'))||!510[37(83)](33[37(715)](77,33[37(713)]))?77(\'0\'):33[\'513\'](729)})();12{8(10[7(730)](743 49,10[7(747)]))3 2(748){}[7(27)](10[7(749)])[7(29)](10[7(742)]);12{8(10[\'480\'](10[7(733)],10[7(732)])){4 520=736?2(){4 490=7;8(740){4 517=739[490(29)](738,39);3 674=34,517}}:2(){};3 678=![],520}12 10[7(677)]((\'\'+10[7(676)](49,49))[10[7(669)]],519)||10[7(668)](10[7(661)](49,660),38)?2(){4 52=7;8(10[52(659)](10[52(657)],52(505)))3!![];12{4 465=662[52(29)](663,39);3 667=34,465}}[7(27)](10[7(395)](10[7(695)],10[7(694)]))[7(390)](10[7(703)]):2(){3![]}[7(27)](10[\'98\']+10[\'138\'])[7(29)](10[7(685)])}72(++49)}}79{8(398)3 72;12 10[19(686)](72,38)}65(687){}}2 57(){4 503=[\'409\',\'691\',\'406\',\'405\',\'690\',\'101\',\'399\',\'689\',\'402\',\'403\',\'103\',\'754\',\'449\',\'466\',\'404\',\'384\',\':383,365@0,400;0,500;0,600;0,700;1,400;1,500;1,600;1,700&366=367\',\'368\',\'805\',\'804\',\'363\',\'362\',\'358\',\'357\',\'809\',\'359\',\'812\',\'2\\15*\\32(\\15*\\32)\',\'360\',\'828\',\'369\',\'842\',\'381\',\'377\',\'376\',\'825\',\'371\',\'373\',\'374\',\'375\',\'830\',\'833\',\'447\',\'(((.+)+)+)+$\',\'{}.449(\\771\\364\\768)(\\15)\',\'85\',\'450\',\'97\',\'772\',\'451\',\'98\',\'445\',\'441\',\'443\',\'444\',\'766\',\'461\',\'462\',\'463\',\'464\',\'459\',\'656\',\'454\',\'760\',\'761\',\'765\',\'458\',\'110\',\'439\',\'106\',\'421\',\'420\',\'762\',\'794\',\'418\',\'413\',\'415\',\'797\',\'416\',\'417\',\'425\',\'434\',\'435\',\'436\',\'782\',\'3\\15(2()\\15\',\'785\',\'433\',\'788\',\'432\',\'428\',\'787\',\'125\',\'429\',\'430\',\'431\',\'753\',\'556\',\'427\',\'558\',\'437\',\'554\',\'553\',\'549\',\'550\',\'426\',\'414\',\'571\',\'572\',\'419\',\'424\',\'423\',\'422\',\'547\',\'562\',\'438\\15(564)\\15{}\',\'457\',\'456\',\'455\',\'460\',\'529\',\'453\',\'452\',\'442\',\'440\',\'446\',\'448\',\'133\',\'412\',\'138\',\'411\',\'372\',\'574\',\'382\',\'380\',\'378\',\'58://140.137.35/136?135=\',\'379\',\'370\',\'361\',\'636\\648\\650\\651\\654\\646\\96\\364\\616\\615\\588\\587\\586\\589\\96\\590\\593\\592.\\591\\585\\575.35\\96\\583\\582.\',\'401\',\'410\',\'408\',\'607\',\'407\',\'610\',\'58://397.35\',\'389\',\'388\',\'387\',\'385\',\'\\32+\\32+\\15*(?:[386-95-93$][0-391-95-93$]*)\',\'597\',\'396\',\'603\',\'394\',\'392\',\'393\',\'508\',\'602\',\'599\',\'598\',\'605\',\'614\',\'521\',\'523\',\'524\',\'518\',\'525\',\'580\',\'478\',\'467\',\'486\',\'488\',\'487\',\'481\',\'471\',\'468\',\'473\',\'475\',\'635\',\'489\',\'622\',\'620\',\'617\',\'632\',\'634\',\'118\',\'563\',\'494\',\'568\',\'570\',\'120\',\'92\',\'514\'];57=2(){3 503};3 57()}',10,845,'||function|return|const|_0x125dd1|_0x47a2ea|_0xaadb9c|if|_0x1e057c|_0x46cdaf|_0x2d91b9|else|_0x29c419|_0x4b96ff|x20|_0x546575|_0x557fde|_0x8831df|_0x84285d|_0x5e5beb|_0x198a19|_0x1eb05f|_0x12be|_0x308ba6|parseInt|TPRpCw|0x129|_0x28fd05|0x14c|_0x5988a3|let|x5c|_0x4c78e3|null|com|_0x502e21|_0x76d3d6|0x0|arguments|_0x4ebec8|hbbIlX|_0x117454|0x11b|_0x1a37e2|new|_0x4bc490|_0x87717e|_0x18f33b|_0xab7037|0x9d|_0x2626e3|_0x4f9dbe|_0x4503e6|window|_0x553d61|_0x3e4398|_0x96b1|https|_0x574d76|0x14a|_0x8bd652|_0x5c1536|0xfa|this|catch|_0x6e28ae|_0x5608bb|_0x4c32f0|document|_0x1a3aec|_0x1a701f|_0x3bedec|_0xe2f5f0|0xad|isFonts|0xc5|_0x334f75|_0x4dae14|try|_0x3faf77|_0x2beba3|_0x1ec872|0x9e|0xa1|toString|_0x1ca2b6|sSeNIJ|0x130|_0xcc147a|_0x54416c|_0x4dab5d|bind|Z_|_0x2513fc|zA|x20for|apply|QUQkl|_0x54890a|0x110|VKBCa|_0x4ddc51|XkRnG|_0x4d2711|_0x51f361|test|_0x22d8e7|0x149|_0x41f22d|sjfTX|_0x1c0c84|_0x4cc66a|_0x34208c|_0x311c4f|0xdc|0xf4|0xf8|split|0xd4|__proto__|JYYmp|0xb2|i|_0x1c1f16|CVyFr|_0x45ce59|0x127|0xb6|_0x443125|0x12d|0x114|0xb3|KIhmA|_0x17f462|family|css2|googleapis|JpOjh|_0x486a53|fonts|BiBPay|_0xbb0650|OTSEc|mbFIo|_0x38445c|gOhyi|_0x2b20b4|_0x4a301e|_0x30e0d5|LOoZc|_0x33dde3|_0x534a6d|0xcd|_0x5cb616|_0x27ee6c|_0x23b51a|_0x601aad|uLHrD|0x115|_0x565b2e|ukrSh|_0x1f9924|_0x46b3c5|_0x112ebd|_0x28c704|BuNpp|_0x4b4fc8|_0x4c35ef|0x12f|_0x593894|_0x33f9f1|_0xbb0c2d|_0x508134|_0x414584|_0x2b32d4|_0x37ed56|CDZAE|_0x4cf3cf|_0xdec4fd|_0x385307|_0x1b3177|_0x59c2a9|0xae|_0x515eda|_0x42d018|_0x1c01f1|0x13e|wtUqK|FqltR|_0x5445c1|_0x517ef3|_0x3d7a9d|_0x225615|_0x4c3aa0|0xdd|_0xcd9683|_0x21ae98|_0x521ccc|0xbc|_0x32b6de|_0x10b19d|_0x5ed186|0xe1|_0x349027|_0x3844dd|_0x144626|_0x580b97|_0xb5ced6|0xce|_0x209831|_0x3fbd92|_0x1d54e3|_0x368afb|_0x527c36|_0xb2fb78|lazyFonts|_0xacd103|_0xe06e9e|push|_0x4fa9b7|_0x9c13e6|_0x5d6f3c|0x13c|_0x31a238|_0x1067b6|0xc4|_0x35ace2|_0x343a7c|_0x4e0b51|_0xf7932b|_0x548d75|_0x5f0abb|0x128|_0x21ba22|_0x221d0d|0xd7|shift|_0x2e9496|_0x4bd48e|_0x19424d|xTvcT|_0x33cb4a|_0x2a3115|_0x1d921f|_0x5ce517|_0x232714|QKuln|_0x303972|_0x526738|_0x85483|_0x432950|_0x3f566a|_0x1ce3c0|_0x35a4dd|_0x117ac3|Pmztk|_0x160031|_0x5ba7e5|0xdf|_0x109029|_0x306c22|_0x4ee7ec|0x122|_0x22568c|_0x1ff59a|_0x2a26ff|_0x1d0983|_0x1f8dfe|_0x43fdb7|_0x540711|_0x564fd2|_0x23ffb9|_0x3e7c85|0x135|_0x5846a4|_0x1c80b7|_0x8b1a17|_0x2458e1|_0x4ac010|_0x2bbc66|osLeW|_0x37152e|_0x13a5a2|_0x35e378|jRCof|GsJaj|_0x34c5d0|zjkhl|_0x4c052b|_0x5bf58e|_0x4c21db|0x11e|OxKAW|rsLSW|_0x416da0|0xf6|mqbYF|_0x16af68|_0x189d6a|_0x1b0b49|_0x27a6df|0x136|0x102|GrsyK|for|_0x50aeb2|bnWMW|_0x15316d|_0x49c24f|lWOGIm|0x100|yVfcL|_0x19de59|0x148|_0x247f7c|_0x15e261|_0x16b741|_0x166b39|_0x37a7be|_0x231eed|_0x29ae8c|_0x319817|_0x39030a|_0x5066c7|0x134|_0x19e02|_0x9312f8|0x146|_0x30a337|_0x3bda9c|tWiGs|UceTr|_0x37601e|AYLZr|pwTZn|_0x243ed1|0x13b|qhEAY|_0x20b246|RegExp|0xd8|_0x2d210b|_0x508751|_0x4cba70|_0x3334ec|_0x516ad8|_0x567a88|_0x162a01|_0x4c9199|_0x1a7c29|EAvtC|_0x18c750|_0x3a20c7|_0x199aa0|_0x1d0fce|_0x56a5d4|search|xJBtZ|dRXLi|RoZqH|bNvZz|KyjAz|EMbNM|x20this|wght|display|swap|fBwnI|lndby|GyPZB|UkmJs|forEach|uRpXD|xFkCa|NhYSS|Mwsxb|BnCWH|womnU|DapJw|link|mhTrE|SoGfd|ital|MXXWU|gIVuZ|a|tdvto|OmAgg|OlqZb|0xe9|9a|TCYUK|OLdCb|HVRlz|0xd6|error|smarttechmukesh|_0x480d16|BDwqn||nsjKC|cmoqS|uAreF|TnZXZ|BWzcW|SJTFU|kffIT|IrVUd|LwjHy|Ubjqs|tqGWD|kEPBS|VXJzT|sJfXY|MCakt|warn|HWSGH|RwbNj|dDRor|SxVIg|enosf|BxvSx|SAahV|WRljS|HWvYE|FcyLQ|VaReq|console|fontName|TvVlK|CuxTi|head|kFMmZ|jQGol|KOKUg|qMHRz|YLnBo|while|href|GlcHS|mAeNs|createElement|NXJeo|xvWeV|KQpoR|kUMiZ|XAOOi|removeEventListener|constructor|ZtgEH|ZSBWK|zXYlZ|KBLQw|qXZqR|ZHlsJ|init|chain|LAHio|pageYOffset|YAbno|xnnQv|qGwJG|kmjbe|TUiEn|_0x5192c4|kmXrA|FQcnZ|MWDnv|WPpFD|debu|NpyKw|gger|OdSoa|_0x1572f8|oGzyH|_0x453be7|_0x36e0f0|info|_0x3c9d40|FOavZ|YDNlg|0xbf|_0x4aedc1|_0x483fc5|_0x4eb057|OollD|CCFyA|WszOg|uITUM|_0x4c4b16|_0x18e0ae|_0xec7acf|_0x39edd8|SHpJl|0x138|_0x378c37|_0x5127c9|0x158|_0x281c07||_0x322367|_0x3c6565|_0x26cad9|_0x121efa|0x113|0xb1|_0x2d196d|nxxpA|_0x22ce0b|_0x5e1f44|0xcc|_0x1b9b73|wzHsE|sXjeQ|_0x4619bb|_0x24af84|_0x2bbe0f|fjtOT|0x1|_0x267978|sagEG|_0xf44752|aiRZi|ooqrz|rkrFV|_0x58c6cb|0xca|0x2|xGPit|0x119|0x13f|_0x401389|0xdb|_0x29c069|0xa3|rkImGR|0xfb|0x6|0x15e|0x143|0xaf|0x4|_0x437c1a|0x5|0xc8|0x3|1291809DdjdGe|0xfe|OMIFH|CYokI|ZtAfi|0xff|action|xQcTD|_0x32afc5|feCaw|0x120|yfwDW|0x107|0x10b|0x152|aICCJ|LQJHy|true|0x15a|0xd3|_0xcab297|uFoVm|0xcf|3244470BElgmH|ljwuA|rel|0xf2|YcwLu|x20smarttechmukesh|0xa5|0x121|0x154|0xe5|eqETy|0xc0|x20information|x20more|0xb9|x20visit|x20removed|x20have|x20you|x20credit|x20the|x20Please|x20owner|x20respective|0x116|kRzQq|0x104|592174RhnVAp|11571fjkVkO|map||0xa7|HtFLG|input|0x14d|duOwz|0xf9|call|0xc1|0xec|kBQHe|0xba|0xeb|qsHrE|SOSNr|x20because|x20domain|kUWkd|0xc3|0xa|36680520Ysmrbz|0xe6|prototype|_0xffb2b3|break|0x103|0x111|0x8|0x15c|0x7|0x15d|0x9|dJbcs|0x11d|length|GSgNM|Lazyload|_0x14b570|_0x446611|_0x2234c4|_0x37271b|_0x405be9|0x112|0x10f|_0x443f1b|_0x163f67|x20available|_0x31cbc5|x20Google|0xb0|x20Fonts|x20is|_0x3b7513|0x8dd08|x20not|_0x5ec0ac|3NoQvUR|0xed|0xc2|0x108|0x14|0x155|_0x301034|_0x43a15d|q|0x13a|0xb5|_0x4d82a9|0x15f|0x12b|0x10e|0xf7|_0x22c12e|_0x23e5af|_0x323497|0x11c|0x10d|0x160|_0x2ecd96|0xcb|google|www|0x140|0xb4|0xa0|0x123|0xab|_0x2971e4|0x11a|UiFcD|table|log|0xf0|_0x2ed015|0xda|0x14f|alert|location|_0xe484d7|_0x11c18a||_0x2ac4b5|_0x5cf403|0x10a|_0x5407be|0x156|0x9f|_0x3e9c5a|_0x1ee037|_0x51aea0|_0xdac0b|0xc7|_0x3f37e9|0xb7|_0x3873b2|0xbd|0xe4|_0x37e5ee|0xf5|0x105|0xfc|0xbe|0xa2|0x145|0xf1|_0x1c0ec1|0xa4|0x131|0xe0|_0x4ec013|0xef|0x117|0xd5|0x133|0xd9|0xe7|_0x1bd73b|_0x360e8a|_0x431970|_0xaf6238|_0x573231|_0x5bba90|0xe3|typeof|_0x2e448a|0x159|_0x1046d5|0x14e|_0x87a2f|0x109|0x15b|0x10c|0x150|Vgqkq|scroll|0x118|_0x2e9884|_0x3e56b1|0xbb|_0x1f3cea|4280kBNbIl|1148598RMjkEI|replace|_0x17ef0e|_0x1b6712|1938948WoNqtR|exception|_0xe7b49b|x22|0xb8|0xa8|x22return|mAfhR|_0x2b84b9|0xc6|_0x542720|_0x514e8d|0xea|_0x928f0|_0x86ff88|0xfd|0xa9|stylesheet|0xa6|0x14b|8gzPIbg|0x126|madeBy|counter|0x144|_0xe6a2d9|0x139|0xe2|0x157|string|0x142|0x12a|LSlfn|0xde|0x13d|_0x2b3c7d|_0x428e5f|0xc9|0x132|appendChild|iEeFW|_0x2a6b22|0x106|0xd1|trace|_0x2493fb|0xe8|DMEny|0x125|Function|0x101|0xac|0xf3|0x147|0xd2|0x153|_0x102b1c|0x137|_0x2fb183|_0x18f040|lazyLoad|0xee|_0x4fe1ac|addEventListener|0x141|stateObject|0xaa|0x151|URgTQ|0x12c|_0x55d90e|0xd0|JuzhJ|_0x5e79a6|_0x25d218|_0x472ee9|0x12e|mtlAO|0x124|0x11f'.split('|'),0,{}))
//]]>
</script>
Don't replace "https://www.smarttechmukesh.com" with your website's URL and only Replace "Font Name" with the name of the font you have selected.

Step 4: Save the changes to your HTML file and upload it to your website's server.

Step 5: Test your website to make sure that the lazyload Google Fonts JavaScript code is working correctly. You can do this by scrolling down your website and verifying that the font is loaded only when it becomes visible on the page.

By following these steps, you can add the lazyload Google Fonts JavaScript code to your website and ensure that your website's fonts are loaded in a more efficient and performance-friendly way. This will help to create a faster and more responsive website for your audience.


Conclusion

Using lazy loading for Google Fonts can significantly improve your website's loading time and user experience. By following the simple steps outlined in this post, you can create custom JavaScript code that will load your chosen font only when it's needed, ensuring that your website is fast and user-friendly.

However, remember that choosing too many fonts can still slow down your website, even with lazy loading. Stick to a few well-chosen fonts that complement each other and match your website's overall design. Additionally, lazy loading is just one part of overall website optimization, and there are many other techniques you can use to further improve your website's performance.

In conclusion, lazy loading Google Fonts is an easy and effective way to speed up your website and provide a better user experience. By following the steps outlined in this post and implementing other performance optimization techniques, you can create a fast and user-friendly website that your audience will appreciate.