backend and finalizing