Background change after n seconds in CSS

Let's assume that we want to change the background of an element from white to black after 10 seconds:

<div class = 'Change'>
    Background will change after 10 seconds. 

And the CSS:

    animation: swapBackground 10s;

@keyframes swapBackground{
   from {background: white;}
   to   {background: black;}

Hi, I'm Erik, an engineer from Barcelona. If you like the post or have any comments, say hi.