Hi,@Paul Marangoni
The problem only happens when I load the site via a link within an email. Both TempData and Session don't seem to be available until the site loads
I tried to reproduce your issue,the cookie(Session cookie/tempdata cookie) might be blocked by samesite policy in your scenairo You could check how you configured TempData cookie in program.cs
builder.Services.Configure<CookieTempDataProviderOptions>(options =>
{
options.Cookie.Name = "TEMPDATA";
//you have to avoid setting SameSiteMode.Strict here
options.Cookie.SameSite = SameSiteMode.Lax;
});
You could check the cookie in browser:
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment". Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread. Best regards, Ruikai Feng