Code Lyoko Wiki
Code Lyoko Wiki

Just in Time is the thirteenth episode of Season 1 of Code Lyoko.


The episode begins with Jeremie saying that the Interface Transfer is activated, along with the Virtual Memory and etc. He also states that the scanners are ready. He then says that this time it will work, and asks Aelita if she is ready. She says yes, and then Jeremie activates the materialization program. On his screen, Aelita's wire-frame loses color to around her head, and a (+) message appears, and so the materialization starts to work, and Jeremie then goes to the scanner room to see. The Scanner opens and then the view turns to the other.

Ulrich and Yumi are practicing Pencak Silat while Odd is playing fetch with Kiwi. Yumi then asks Odd if he's seen Jeremie this morning. Odd thinks he spent all night in the laboratory working on something very important. The three Lyoko Warriors then say, "Aelita" in unison. Yumi then kicks Ulrich. Ulrich says that he thought there was a time-out (but no one ever called a time-out). Jeremie runs as fast as he can to the other and lets them guess what he did. Odd answers that it had something to do with materializing Aelita. Jeremie then informs all three that he "finally did it". He shows them a test tube. Ulrich then asks, "You materialized a test tube?" Jeremie then tells them to look inside, showing it contains a single pink hair. Odd then asks that he only materialized one hair. Jeremie says that it's Aelita's and Yumi asks how he managed to do that.

They then head to the factory. Jeremie goes on a spiel that is a bit too long for them, but he gives the vital information that the hair contains Aelita's entire genetic/computer code. Jeremie then asks if it was simple enough and if they follow. Odd says no, and then Jeremie asks if it was "No, it's not simple enough, or no, you don't follow?" Odd says, "Uh... 'no' means we take your word for it." Aelita on the screen then puts her hand on her face and giggles. Jeremie says that it is no problem and that it will become clear when Aelita is there in flesh and blood. Ulrich asks if Jeremie will materialize her at that same time. Jeremie says that the hair was just a test before he does the entire thing. Yumi says, "Listen, making a hair appear is one thing, and materializing Aelita is not the same!" Jeremie then says that if they want to spend their whole life fighting X.A.N.A., and that when Aelita is finally materialized, they can deactivate X.A.N.A. once and for all. He then reactivates the program, but the window displays (!), signifying the program does not work. Jeremie says that he planned everything so perfectly. Ulrich says that he will be ready in a few days and that he is almost there. Odd then checks his watch, surprised, and says, "Hey, come on, guys, if we don't materialize in the classroom, we're not going to last a few days!"

After class, during lunch break, Jeremie wonders what happened. Yumi asks if the hair, containing the entire gene code, gives enough for the parameters for materialization, what would have been possibly wrong in the first place. Odd says that he is only a "hair" away. Ulrich then says that with all the hairs Kiwi sheds, he could practically make him another Kiwi. Sissi then comes up and says she'll keep quiet about Kiwi if Ulrich will be nicer to her. Yumi then threatens her, squeezing the glass barely, breaking it anyway in the process. This scares Sissi off, but causes a cut to form on Yumi's hand.

In the infirmary, Yolanda puts a bandage on Yumi and says the cut is not very deep. Yumi says she only barely squeezed the glass. Ulrich says that she shouldn't worry as it was a cheap glass not the Chinese porcelain and now he at least knows what to expect when she gets angry, to which she smiles. Then, Ulrich gets a phone call from Jeremie, who tells him to meet him in his room.

Once they convene in the room, Jeremie says it is a disaster, as after he had checked Aelita, he discovered that Aelita's program is all full of bugs. He says that, during the hair's materialization, he hit a button he shouldn't have pressed, and therefore damaged the Annex Program. This means that the program linking Aelita to the towers is corrupted; the next time she enters the Code LYOKO into the tower, she'll be reformatted and deleted (she'll disappear forever). Aelita says that a program can be de-bugged, and that they can do it together. Jeremie then asks the three to make up excuses for the teachers, vowing to not leave the computer until he's fixed this problem. Ulrich and Odd walk to their room to find Kiwi barking. The window breaks after he barks. Jim sees the window broken (but not Kiwi). Jim then says to Ulrich, "Clean up your bed; there's hair all over it."

Odd then sends Kiwi to Jeremie's room. Jeremie, with the help of Aelita, is trying to fix the Annex program, but Kiwi begins chewing on Jeremie's clothes and annoying him. The barking is causing damage to the school floor as Sissi is walking past and screams as the building quakes again.

At the factory, X.A.N.A. has just woken up and Aelita feels pulsations. Aelita then tells Jeremie and he says "It can't be. Not now!". He launches a program to search for the activated tower and to his despair it shows one activated tower. The scene then takes for Jim and the Principal; Jim suggests humidity caused it, but the Principal says that it didn't look very damp. Jim then suspects that there is a dog (possibly Kiwi) and runs to dorm door to dorm door, and as soon as he hit's Jeremie's dorm the wall on the right starts to crack. Jean Pierre Delmas says that they need to evacuate the building. Ulrich says "It's X.A.N.A.", and Odd says "Oh, yeah, it's him…" The two begin to discuss Kiwi's ability to sense the attack and believe X.A.N.A. is using ultrasound to weaken the school's structures. The principal then announces over the school intercom that everyone was to evacuate the school buildings immediately. Realizing that Kiwi is still in Jeremie's room, Odd leaves and Ulrich calls Yumi as he heads for the Factory.

In the dorms, Odd gets Kiwi and as he's leaving he finds Milly and Tamiya in their room (both of whom had not heard the principal's announcement) and warns them that they must leave. Together, they head for the stairs and as they are about to descend, Kiwi barks and another quake hits the building which destroys the stairs, they turn and try to head the other way but find that they are trapped as the quake had destroyed the hallway behind them. Ulrich arrives at the lab and explains the situation to Jeremie, Odd then rings Ulrich and tells him what has happened at the school and tells him to go ahead to Lyoko, another quake then hits the building causing the floor he, Milly and Tamiya are standing on to tilt and he drops his phone. Ulrich tells Jeremie that there is no other choice than to send him to Lyoko.

Yumi meanwhile is on her way to Kadic when she sees that X.A.N.A. is now attacking the city with the ultrasound system and quickens her pace. Ulrich is transferred to the Forest Sector where he and Aelita begin to make their way to the tower, not realizing that they are being followed by a group of Kankrelats. Yumi arrives at Kadic to see the school in ruins and a teary-eyed Sissi who tells her that Odd, Milly and Tamiya are still inside the building. Another quake strikes and Odd spots the next floor down and instructs the girls to slide down with him to a safer spot.

On Lyoko, Ulrich and Aelita reach a crossroad when the Kankrelats attack, striking Ulrich in the leg. Yumi arrives at the factory to that it too is cracking from X.A.N.A.'s attack. Jeremie transfers her immediately to Lyoko, meanwhile, as Ulrich and Aelita attempt to flee the monsters, they reach another crossroad and are surrounded when Yumi shows up and they manage to destroy the Kankrelats. They then run down another path and spot the tower.

In the school, Odd has gotten himself and the girls down to the lower floor and they are horrified to find the exit blocked off by rubble when another quake strikes. On Lyoko, a Krab appears, Ulrich manages to defeat it but it is immediately followed by three more forcing Ulrich, Yumi and Aelita to take refuge in a hollow tree root. Jeremie then states that he has finished the repair program and tries to run it but to no avail, at the same time the roof of the lab is crumbling around him. Aelita then makes the decision that even though she faces deletion, she must deactivate the tower. Despite, Jeremie's protests, the three move out, Ulrich manages to destroy one of the Krabs but is devirtualized by one of the other while Yumi takes Aelita towards the tower. Aelita gives Yumi a wave and heads into the tower, Yumi then manages to destroy another Krab. Knowing that Aelita has made it to the tower, Yumi spreads her arms and allows her to be devirtualized by the last Krab.

In the school, a large series of quakes has begun to strike causing rubble to fall everywhere, Odd, Milly and Tamiya huddle close as part of the building begins to sink. In the tower, Aelita ascends to the upper floor and with Jeremie begging for her to stop, she bids him goodbye and enters the Lyoko code. The quakes suddenly stop at Kadic and Jeremie, sad, launches a return to the past.

The group is in the lab, mourning Aelita, and trying to convince Jeremie that it wasn't his fault she is gone. Yumi then suddenly remembers and asks if the hair that was materialized could restore Aelita. They place it in the scanner and watch as Aelita's codes are restored and Aelita reappears on Lyoko in one of the towers. The group is overjoyed and when Aelita asks what is wrong Jeremie states that "This time we only missed, by a hair", the group then laugh as X.A.N.A.'s pulsations stir once again.


  • The original French name of this episode is D'un cheveu, which translates to By a Hair.
    • The French title is a double entendre, as it literally refers to Aelita's hair follicle that saves her, but also refers to the French expression "Il s'en est fallu d'un cheveu" (lit. "it was a hair's breadth away"), used to refer to events that nearly, but didn't, happen, similar to calling something a "close call" in English.
    • When this episode was first uploaded to the Official US YouTube Channel on September 5th of 2015, it was mistakenly given the title By a Hair's Breadth, an alternate translation of the French expression mentioned above. This was only fixed around April of 2023 in the video's title, although the description still refers to the episode by the wrong name.
  • The English name of the episode, Just in Time, is likely a nod to Aelita almost being deleted for good, only to be saved "just in time" by Yumi coming up with the idea to recreate her from her hair.
    • The English title could also be a double entendre itself, referring to Just-in-time compilation in computer programming, commonly abbreviated JIT, which is a form of compilation that occurs at the run-time of a program rather than after. Normally JIT involves translating bytecode to machine code, but in this case it can be inferred that the title is referring to way that Jeremie "translates" Aelita's machine code from Lyoko into human DNA in the form of her hair, along with when he does the reverse at the end of the episode.
    • Another reason the title may have been changed in English is to avoid spoiling the episode's twist to the viewer, as referring to Aelita's hair in the title places emphasis on it and may give away the twist to some.
  • Kiwi's constant barking XANA's attacks is scientifically accurate. Dogs are capable of sensing ultrasonic phenomena that would be otherwise imperceptible to humans. For instance, dogs are capable of feeling a storm coming by sensing the drop in barometric pressure, meaning Odd's hypothesis about Kiwi feeling the attacks coming over the ultrasonic spectrum wasn't too far off.


  • English dub error: After Jeremie talks to the group and leaves them to go to the factory, Yumi's face is shown speaking. However, it is Ulrich's voice that is heard. According to Barbara Weber-Scaff, this happened as a result of the show's dubbing process. The person who translated the dialogue accidently wrote Ulrich's name instead of Yumi's, and because the band with the dialogue cut off part of Yumi's face, neither the director nor the voice actors noticed the error.[1]
  • English dub error: Another arguable error is made when Mr. Delmas announces to evacuate the school. During the announcement he says to "evacuate the building" and later that "no one will be permitted to enter the building", both singular. This is technically wrong as Kadic is made up of multiple separated buildings, multiple of which were in use during the announcement, but it's possible he was just referring to the entire school's grounds as a single unit that needed to be evacuated as he also instructs everyone to "leave the immediate area".
  • From 10:37 to 10:42, when Odd and Ulrich are walking together, an outline around the purple part of Odd's hair continuously appears for one frame before disappearing for the rest of his walk cycle.
  • When Mr. Delmas does the announcement to evacuate the school, Emily LeDuc and Azra Ürgüp appear both in Ms. Hertz's classroom and in the courtyard.




  1. Reply from Barbara Weber-Scaff: "We've figured it out since then. The error was one of "detection" the person writing the lines on the band that we follow to get the lines synch with the image. Because the bottom part of the face was hidden by the band, the director (not to mention US) didn't notice that the line that was written "Ulrich" was actually Yumi onscreen. It was just one of those things that slipped through the gap..." Lyoko Freak. November 17, 2005.