Emotions plays a crucial role in daily life. Detection of emotions from social media text is paying attention in sentiment analysis, social monitoring. Enhancement of internet technology increased use of social media. Nowadays social media text is used for wide varieties of application as it contains implicit expressions, feelings, thoughts, moods. Sentiment analysis extracts sentiments, aspect, emotion, opinion and view from the text, videos, audio. Extraction of accurate sentiments or emotions from users and to analyze such data is a challenging task. Various approaches are developed to extract emotion from text which includes classification algorithms, machine learning, deep learning techniques, rule-based approach, hybrid approach etc. Extraction of implicit emotion from user text is still a challenging area. This study aims to give insights into analysis of different machine learning algorithms such as Support Vector Machine, Random Forest Classifier , Decision Tree, Extreme Gradient Boosting , Naive Bayes Classifier and deep learning techniques such as Convolutional Neural Network, Long-Short Term Memory, Hybrid models for detection of emotion from social media text based on two different online available datasets, Performance of models is measured with performance metrics accuracy and losses.