A simple web page using significant amount of memory, can it be some security issue? I ran nothing in background, was just viewing stackoverflow questions, and the notifications says it is using significant of memory.

When I checked activity monitor it was using 2GB which is absolute nonsense.

Is it some security issue?
Usually it’s not a security issue. That warning usually comes up due to the programmers behind the page making a mistake, such as a memory leak, which makes the page use an ever increasing amount of memory. It might of course also be a page with an application that simply requires a lot of memory - that’s not usually the case on Stack Overflow though.

Another reason for the warning could be that you have a browser plugin or other software installed (such as antivirus programs) that manipulate the page to insert code, and they then have a bug that results in high memory use. In some countries it could also be an ISP inserting code into pages - but that would usually require you accepting/installing certificates on your computer in advance.

Finally it might of course be related to something with security. However there’s nothing that indicates that here. Usually programs that try to exploit your computer wouldn’t use huge amounts of memory to avoid rousing suspicion. The only way to tell would be to examine the actual page source of the page you’re currently viewing.