A method for using a laser to create a pocket in a patient's cornea is provided. The pocket is created using a femtosecond or a nanosecond laser. The laser ablates tissue within the cornea in a specific shape. The shape of the pocket can be determined by software to custom program a three-dimensional path of the laser. A variety of corneal pocket configurations or computer programmed shapes can be used accommodate various corneal lens shapes and sizes. An intracorneal lens can then be inserted into the pocket, in order to correct the patient's vision.