Cost basis is the amount of a taxpayer's investment in a property for tax purposes.  A gain or loss is determined by subtracting out the adjusted basis (discussed later) from the proceeds of the sale, exchange or disposition of property. Your adjusted basis will determine what capital gain or loss you have when you sell the property.

Some rules with basis in determining gain or loss are as follows:

  1. Real property (also called real estate which is anything built on, growing on, or attached to the land): To figure out the gain or loss on the sale, exchange or disposition, a taxpayer must make certain adjustments. These adjustments result in the adjusted basis. Once sold,  the adjusted basis would then be deducted from the property's fair market value to determine the capital gain or loss on the sale.
    1. Some things will increase the basis such as capital improvements (adding a bathroom or bedroom, installing a new roof, etc)  or assessments for local improvements (add property assessments for improvements that increase the value of the property assessed to the basis like roads, sidewalks, etc)
    2. Other things will decrease the basis such as casualty and theft losses, easements, depreciation an section 179 deductions. 
  2. Property received for services: If a taxpayer received property for services rendered, its fair market value ( what it is worth today) must be included in income.  The amount included in income becomes the basis.
  3. Involuntary conversions: If a taxpayer received replacement property because of an involuntary conversion, such as a casualty, or theft, or condemnation, the basis of the replacement property is calculated by using the basis of the converted property.
  4. Property received as a gift: To figure out the basis of property received as a gift, a taxpayer must know the adjusted basis to the donor (source of gift), it's fair market value (FMV) at the time of the gift, and any gift tax paid.
  5. Inherited property: With the exception of 2010 transfers electing the modified carryover basis, a gain on inherited property is always long term.  Basis of an inherited capital asset is generally the fair market value of the property on the date of death or an alternate valuation date, if elected by the personal representative.  In other words, no matter what the cost (basis) was, the basis is the fair market value so there will be no capital gain or loss on inherited property, unless it is a 401K or other retirement which in this case is fully taxable income, and thus a capital gain property.