How to get a RTC from wifi module

I have an arduino nano 33 IOT and was wondering how to get a real time clock using the wifi shield included with the board. I have no expertise in using the wifi shield at all and don't know how to pull data from online

Try working your way through the examples and tutorials that come with board and its libraries.

Here is the Getting Started guide. You might even notice that one of the tutorials is titled “WiFi RTC”.

WiFi.getTime() returns ‘epoch’ seconds
use it with the Time library

#include <TimeLib.h> // in LibraryManager as “Time”

in setup():


test loop()

void loop() {

 char buff[20];
 sprintf(buff, "%02d-%02d-%02d %02d:%02d:%02d", year(), month(), day(), hour(), minute(), second());