WEBVTT - How Internet Cookies Work

0:00:00.520 --> 0:00:03.600
<v Speaker 1>Welcome to brain Stuff from how Stuff Works dot com

0:00:03.600 --> 0:00:15.000
<v Speaker 1>where smart Happens. Hi, I'm Marshall Brain with today's question,

0:00:15.480 --> 0:00:20.000
<v Speaker 1>what is an Internet cookie? Cookies have for some reason

0:00:20.160 --> 0:00:24.720
<v Speaker 1>gained a rather sinister image, but they're really simple and harmless.

0:00:25.040 --> 0:00:28.520
<v Speaker 1>A cookie is just information stored as text strings on

0:00:28.640 --> 0:00:32.640
<v Speaker 1>your machine by a web server. A web server sends

0:00:32.680 --> 0:00:35.159
<v Speaker 1>you a cookie, and the browser stores it on the

0:00:35.200 --> 0:00:38.800
<v Speaker 1>hard disk. The browser then returns the cookie to the

0:00:38.840 --> 0:00:42.360
<v Speaker 1>server the next time the page is referenced. The most

0:00:42.400 --> 0:00:45.360
<v Speaker 1>common use of a cookie is to store a user

0:00:45.400 --> 0:00:48.800
<v Speaker 1>I D. For example, a cookie might contain the following

0:00:48.880 --> 0:00:54.040
<v Speaker 1>string I D equals nine six three five. Amazon dot

0:00:54.080 --> 0:00:57.400
<v Speaker 1>com is one site that uses this technique. When you

0:00:57.520 --> 0:00:59.680
<v Speaker 1>order a book, you fill out a form with your

0:00:59.760 --> 0:01:03.720
<v Speaker 1>name address. Amazon assigns you an i D in its database,

0:01:04.200 --> 0:01:07.399
<v Speaker 1>stores your information with that i D on its server,

0:01:08.080 --> 0:01:11.280
<v Speaker 1>and sends the i D to your browser as a cookie.

0:01:11.680 --> 0:01:14.560
<v Speaker 1>Your browser stores the i D on your hard disk.

0:01:14.800 --> 0:01:17.480
<v Speaker 1>The next time you go to Amazon, the idea is

0:01:17.560 --> 0:01:20.679
<v Speaker 1>sent back to the server. The server looks you up

0:01:20.760 --> 0:01:23.520
<v Speaker 1>by your I D and customizes the web page that

0:01:23.600 --> 0:01:26.319
<v Speaker 1>sends back to you. In essence, it knows who you

0:01:26.360 --> 0:01:29.880
<v Speaker 1>are so it can say welcome back, Joe Smith. You

0:01:29.959 --> 0:01:34.120
<v Speaker 1>might be wondering, is there any more to cookies than that. No,

0:01:34.720 --> 0:01:37.920
<v Speaker 1>they are simply text strings stored on the hard disk.

0:01:38.280 --> 0:01:40.880
<v Speaker 1>They are little text files. You can open them up

0:01:40.920 --> 0:01:44.200
<v Speaker 1>and see the strings that are being saved. There's nothing magic,

0:01:44.600 --> 0:01:49.320
<v Speaker 1>there's nothing complicated about it. Our cookies harmful? No, They're

0:01:49.400 --> 0:01:52.480
<v Speaker 1>just short text strings, and they can often make browsing

0:01:52.560 --> 0:01:56.800
<v Speaker 1>better by allowing a server to recall any customized information

0:01:56.880 --> 0:02:01.200
<v Speaker 1>you've set our cookies comment. Yes, the typical machine has

0:02:01.600 --> 0:02:05.160
<v Speaker 1>hundreds of separate cookies on the hard disk. Can cookies

0:02:05.200 --> 0:02:10.320
<v Speaker 1>transmit computer viruses? No, they're just text strings. Can accompany

0:02:10.480 --> 0:02:14.440
<v Speaker 1>read your personal information from your hard disc with a cookie? No?

0:02:15.000 --> 0:02:17.920
<v Speaker 1>Only the cookie that is sent in the first place

0:02:18.000 --> 0:02:21.360
<v Speaker 1>is returned to the server. It's not modified or manipulated

0:02:21.400 --> 0:02:25.600
<v Speaker 1>in any way. Be sure to check out our new

0:02:25.680 --> 0:02:29.040
<v Speaker 1>video podcast, Stuff from the Future. Join How Stuff Work

0:02:29.120 --> 0:02:32.639
<v Speaker 1>staff as we explore the most promising and perplexing possibilities

0:02:32.680 --> 0:02:36.840
<v Speaker 1>of tomorrow. The How Stuff Works iPhone app has arrived.

0:02:36.919 --> 0:02:38.880
<v Speaker 1>Download it today on iTunes.