The instance of entity type cannot be tracked because another instance of this type with the same key is already being tracked
Without overriding EF track system, you can also Detach the ‘local’ entry and attach your updated entry before saving : // var local = _context.Set<YourEntity>() .Local .FirstOrDefault(entry => entry.Id.Equals(entryId)); // check if local is not null if (local != null) { // detach _context.Entry(local).State = EntityState.Detached; } // set Modified flag in your entry _context.Entry(entryToUpdate).State … Read more