JS Coding Questions Logo
JS Coding Questions
#38💼 Interview💻 Code

What is a Cookie

Advertisement

728x90

A cookie is a piece of data that is stored on your computer to be accessed by your browser. Cookies are saved as key/value pairs.

For example, you can create a cookie named username as below,

javascript
1document.cookie = "username=John";
Screenshot

Advertisement

Responsive Ad
🎯 Practice NowRelated Challenge

JavaScript Coding Exercise 40

Test your knowledge with this interactive coding challenge.

Start Coding

Advertisement

728x90
38of476