Most carpeting is held together on the underside with glue and a rough textured crosshatch mesh. When you cut a piece of carpet, it frays the edges of the underlying mesh on the cut side. Over time, this fraying can worsen, eventually causing the carpet fibers on top to fray as well. Fortunately, there are two quick fixes for this. Install a threshold transition if your cut carpet is being installed up against another type of flooring material, or you can fix it with a combination of carpet glue and carpet tape.
Make sure that a threshold strip is called for in your situation. This solution should only be used when you've cut a section of carpet so that the carpeting will go around another type of flooring material. For example, if you have just put down carpeting in a front living room but there is a tile section immediately in front of the front door, as is common in home design, you'll have cut carpet edges all along the border of the tile. This is a perfect situation in which installing a transition strip can make the floor look great while protecting the carpet edges.
Measure the length of all borders between the carpet and the other flooring material. Count how many corners there are, as well.
Shop for threshold transition strips, which are available in many sizes and styles and which can be found at most hardware and home remodeling stores. Purchase transition strips that are the right size for your application. If you need to join a corner with two transition strips, be sure to purchase a matching corner cap for each joint.
Lay out all of your transition strips in place along the borders between the carpet and the other flooring material. Lay out any corner caps as well. This is just to make sure all of your parts are accounted for and that everything fits together nicely before you start screwing the strips into place.
Install each strip by placing it on the border between the flooring materials, with half of the strip on the carpeting and the other half on the other flooring material. When the strip is in place, use an electric drill to drive a wood screw through the holes in the strips and directly into the subfloor.
Install any corner caps, which screw down into place just like the strips. The corner caps must be installed last, on top of all the installed strips.
Turn the carpet upside down and lay it flat where you can easily reach all of the cut sides.
Spread a thin layer of carpet glue along all of the cut edges of the carpet. Use a popsicle stick to spread it around, and create about a one inch border along all of the cut sides.
Allow the glue to dry completely.
Affix carpet tape to the edges of every cut side. You can do this in long, continuous strips. If you find it easier, several shorter and more manageable strips can be used. The tape should go right on top of the glued sections, and the outside edge of the tape should be flush against the outside cut edges of the carpet.