# SharedFlow and StateFlow

DevFeed: [SharedFlow and StateFlow](<https://devfeed.tech/articles/sharedflow-and-stateflow-39238.md>)

Original publisher: [Read original article](<https://kt.academy/article/cc-sharedflow-stateflow>)

Published: 2022-02-21T00:00:00Z

Content type: tutorial

Language: en

Sources: [Kt. Academy](<https://devfeed.tech/sources/kt-academy.md>)

Topics: [Coroutines](<https://devfeed.tech/topics/coroutines.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [Android](<https://devfeed.tech/topics/android.md>), [RxJava](<https://devfeed.tech/topics/rxjava.md>)

Tags: [channel](<https://devfeed.tech/tags/channel.md>), [coroutines](<https://devfeed.tech/tags/coroutines.md>), [flow](<https://devfeed.tech/tags/flow.md>), [interfaces](<https://devfeed.tech/tags/interfaces.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [livedata](<https://devfeed.tech/tags/livedata.md>), [rxjava](<https://devfeed.tech/tags/rxjava.md>), [scope](<https://devfeed.tech/tags/scope.md>), [sharedflow](<https://devfeed.tech/tags/sharedflow.md>), [stateflow](<https://devfeed.tech/tags/stateflow.md>), [value](<https://devfeed.tech/tags/value.md>), [values](<https://devfeed.tech/tags/values.md>), [workshop-learning-programming](<https://devfeed.tech/tags/workshop-learning-programming.md>)

## AI overview

A tutorial explaining Kotlin's SharedFlow and StateFlow for broadcasting and observing values among multiple coroutines. It covers replayed values, cancellation, interfaces for collecting and emitting, and converting a Flow with shareIn.

## Source excerpt

Known as a replacement for Subject, LiveData, and many more. SharedFlow and StateFlow are powerful coroutines classes, every Kotlin developer should know.