In today's smart applications, very frequently used data like electronic health records (EHR's) are highly sensitive and soft target to the unauthorized agencies. Data management, integrity, and security issues plague EHR systems. Insurance firms are prohibited by law and corporate privacy from sharing patient data, but because the data are not linked and synchronized among insurance providers, there has been a rise in healthcare fraud. A crucial component of an e‐health system is safe communication between patients, healthcare providers, and insurance companies. Building a system to securely manage and track insurance operations by combining data from all sources is required to combat health insurance fraud. Over time, blockchain grew in popularity, and the healthcare sector's interest in it led to the development of design concepts that addressed security issues. In this study, a blockchain‐based security architecture has been presented to protect the EHR and provide a secure method for patients, their caregivers, physicians, and insurance agents to access the clinical data of the patients. By using off‐chain storage and cryptographic key exchange through blockchain our approach also covers the scalability, integrity and access control issue that a healthcare system in general is facing.A crucial component of an e‐health system is safe communication between patients, healthcare providers, and insurance companies. A blockchain‐based security architecture has been presented to protect the EHR and provide a secure method for patients, caregivers, physicians, and insurance agents to access the clinical data of the patients.