set xdata time set timefmt "%s"
Then gnuplot picks an adequate format depending on the data that you can override. For example, my ECG:
See https://gnuplot.sourceforge.net/docs_4.2/node76.html#Time_date for more syntax.