The cookies are set to expire two weeks from the time they are created. From the codex
The expiration period is set in wp-includes/pluggable.php
as shown below:
$expiration = time() + apply_filters( 'auth_cookie_expiration', 14 * DAY_IN_SECONDS, $user_id, $remember );
You can use the auth_cookie_expiration
filter to change this value.